Posted on Monday 12th November 2007 at 02:23 PM | |
gbt91 Junior Member |
Hi Guys, I Need your help... i 'm coding a new site which has an header and a footer, so now i want to know if there's a way different from having the data on a sql table to make a site based on an index page. index?page= for more info ask me |
Posted on Monday 12th November 2007 at 07:01 PM | |
SkillMaster Senior Member |
Easy peasy.. :) Code <? if (isset($_GET['page']) && file_exists(''.$_GET[page].'.php')) { include("{$_GET["page"]}.php"); } else { include("home.php"); } ?> you go index.php?page= whatever page you want to call just without the extension. :) if there is no page it just goes to your home page :) |