'Shouldn't this $#random_links{$category}; Be this $random_links{$category}; without the hash??...'
No because you need to get a total count.
'because that is what $category does build the top cats in home page????.'
Depends how you do it. Instead of $category you could use $category2
Then in the build stats you'll need to make it so that $category2 is defined. $use a regular expression so that each $category2 is the names of the main categories and the links within them are the links in their sub categories.
Glenn
Links 2 Mods Site:
http://cgi-resource.co.uk/pages/links2mods.shtml
No because you need to get a total count.
'because that is what $category does build the top cats in home page????.'
Depends how you do it. Instead of $category you could use $category2
Then in the build stats you'll need to make it so that $category2 is defined. $use a regular expression so that each $category2 is the names of the main categories and the links within them are the links in their sub categories.
Glenn
Links 2 Mods Site:
http://cgi-resource.co.uk/pages/links2mods.shtml