Thank to all of you that wanted to help - I solved it!
The tree categories is using a javascript class call
dtree
yuo can find it here:
http://www.destroydrop.com/javascripts/tree/
and this is the place to give credit to the developer:
Geir Landrö.
The code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>Category tree</title>
<link rel="StyleSheet" href="dtree.css" type="text/css" />
<script type="text/javascript" src="dtree.
js"></script>
</head>
<body>
<script type="text/javascript">
<!--
d = new dTree('d');
d.config.folderLinks=false;
d.add(0,-1,'Head title');
<?
$dbh=mysql_connect ("***", "***", "***") or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db ("***");
$categories_query = mysql_query("SELECT * FROM categories,categories_description WHERE categories.categories_id = categories_description.categories_id ORDER by categories.parent_id, categories.sort_order,categories_description.categ ories_name");
while ($categories = mysql_fetch_array($categories_query)) {
extract ($categories);
echo("
d.add($categories_id,$parent_id,'$categories_name' ,'mirror.php?cat=$categories_id');
");
}
mysql_close($dbh);
?>
document.write(d);
</script>
I have tried it, and its working perfect!