I’ve got a small php site where my index.php loads content based on the nav links — so a link “http://mysite.com/?page=contact” will load the contact.php file after the header.php, nav.php, and before the footer.php. Works great.
Now I want to use jQuery ajax to load the various ‘content’ php files based on the URL as in the sample above. How do I do that? I’ve tried using the tutorial here (http://css-tricks.com/examples/AJAXReplaceSamePart/) but it depends on using nice neat .html extensions for the links.
I apologize in advance if this is too much to ask. My situation sounds much like the original question. I’ve got a php site with divisions, “header”, “navigation”, “content”, and “footer” in the css and includes in the index.php file for them. My goal is to have a folder with all the content pages which will load into the content division of the index file by clicking on a link in the navigation.php file. This way all I have to do is add a link for a new content page. I’ve read many online articles relating to this but I’m not a coder and they always leave out where the code goes and which variables to change. If I could get some specific example of how to do this, I’d be most appreciative. Here’s a couple of sites I’ve made that I want to change and eliminate the side menu if it’s possible to have enough submenus in the navigation bar to give the content.php more width. http://patrioticrevelations.com/ http://patrioticrevelations.com/gec/