PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
On my website it lists a bunch of products I have for sale. I have made a link so users can edit how the list is shown (list or thumbnails). I want to know how to edit the font on my list so when the user is on list, the font is bold, then when they click thumbnail the text will change to be bold on the thumbnails text etc... I have been trying but no success!
I use a menu.php as the main menu on all pages and use the include code on all other pages.
I want to edit the menu.php basically so when the user clicks a page, the page they are on is bold in the menu.
Typically you would use a list in this case. A table is not neccesary, and harder to style in this case as well. Reguardless, if you want to do this on the server side then it will be a matter of looping your menu elements and checking whether it matches the current url. I just threw in $_SERVER['REQUEST_URI'] but you may need to parse it differently depending on your navigational structure.