Does anyone know where I can learn to base my entire web site off of one index page? I can't seem to find anything.
imzac
0
Newbie Poster
Recommended Answers
Jump to PostIt's using function. You may take a look at http://www.phpfreaks.com/tutorials/1/0.php
Jump to PostI'm not really familiar with PHP, but I imagine the code would look something like this:
<!-- All your header stuff --> <?php if ($content){ require("$content"); } else { require('defaultcontent'); // replace defaultcontent with whatever file. } ?> <!-- All your footer stuff -->
The above could …
Jump to PostAnyone else have any feedback on this. I just came up with this on the fly from the little I do know about PHP. I didn't test this.
Alcides. :rolleyes:
That's about right. I mean, obviously, it can get pretty complicated, as in my two software projects (sorry, only one's …
All 9 Replies
PoA
12
Posting Whiz in Training
kenleycapps
0
Newbie Poster
imzac
0
Newbie Poster
kenleycapps
0
Newbie Poster
imzac
0
Newbie Poster
Alcides
1
Junior Poster in Training
rice_web
0
Newbie Poster
Roberdin
9
Supreme Evil Overlord
Team Colleague
Alcides
1
Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.