php mysql menu
View Single Post
11-28-2010, 05:09 AM
Join Date: Sep 2007
Originally Posted by
i have categories, sub-categories in my database from which i wan to make menu. total number of categories including sub-catgeories is 495 and sub-categories go to a depth of level 3.
i want to know which one will be faster and put less load on my server.
1. i use a function to generate menu every time page is loaded, so every time categories table needs to be crawled. right?
2. since i will update categories one in a while, so i use function to write them in a file in <ul><li> manner and use it as menu so that i don't have to use database
Caching like that will always be faster since it has to make less database calls.
View Public Profile
Send a private message to Village Idiot
Find More Posts by Village Idiot