How do I Create a Dynamic Menu using PHP?

Master4

New member
I trying to design a "dynamic drop menu" for a website, using PHP.

The Code needs to work so that code for the menu is only written once.
Each 'html' page uses the menu refer-ed in PHP file.

I not sure how to do this, but I am assume that I will also need some CSS or Javascript to create the "dynamic drop menu".

Could someone possibly tell me how to go about this?
Provide some sample code or some links?
 
you dont use php for that... you use javascript...

specifically, you download a free one from hotscripts.com, change it to what you need..

you have a file called head.php, another called menu.php, and another called footer.php...

in each "body page" you create, use includes to pull those pages into it... you can create thousands of pages, and use includes of those specific pages, then basically you only change that info once for it to show universally....


include "header.php";
(includes all meta data, title, keywords, <html.> <body.>

include "menu.php";
(the guts of your menu)

your info goes here for the page...

include "footer.php";
copyright, etc etc
</body>
</html>

get it?
 
Back
Top