Call pages with a menu using PHP, like Iframe

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!

Moderator: General Moderators

Post Reply
rscott7706
Forum Newbie
Posts: 1
Joined: Sat Sep 05, 2009 5:45 pm

Call pages with a menu using PHP, like Iframe

Post by rscott7706 »

Hello all, hope you can help - couldn't find anything in search.

I want to set up a template that has a header on top, footer on bottom, content area in middle of screen and a menu on left side of screen.

I want the menu links to call underlying pages written in html to display in the 'content" area.

Much like Iframes, but with the clean coding of php include.

Is this possible?

Ron 8)
User avatar
Robert07
Forum Contributor
Posts: 113
Joined: Tue Jun 17, 2008 1:41 pm

Re: Call pages with a menu using PHP, like Iframe

Post by Robert07 »

Hi Ron,
Yes you could put each section into a div, and include the contents of each one from another file. Then your links would be either to a different page name (which would include a different content) or you could add a parameter in the url which you would check for to determine what to display in the main section. Those are the easy ways of doing it. Or you could use an ajax function which would replace the contents of the main div with the results returned from different files called by selecting different links on the side.
Regards,
Robert
Post Reply