How do you make a simple content change with php script?

globexweb

Newbie
Joined
Mar 29, 2013
Messages
11
Reaction score
0
Hi All;

I'm knew to php. But the only way to learn it is to try, right? So i'm trying to make a simple 5 page web site. I want to use one layout and I want to be able to switch content of the page by clicking a link and using php. If you know how to do this simple script please show me in detail. Thank you.

Regards
Globexweb
 
Have you try mvc approach. Better use existing php framework to separate template with core code. You could have better code flow using Model View Controller.
 
just create a parameter in the link to the content from your site something like
pagecontent=(number)
then use file_get_contents to insert the content from a resource on the server into the template wherever its supposed to go !
 
Back
Top