Forum Moderators: coopster
I made a php content only page for each menu item
index.php is main page. lets use aboutus.php as the content change.
Here is what i tried but content did not come in
<li><span class="menu_r"><a href="index.php?file=sidebars/sepia.php" target="_self"><span class="menu_ar">Home</span></a></span></li> The sidebar/sepia.php would be the content. If this is right it is maybe the include statement in the 'content ' DIV that is wrong
Thanks so much for any post to this.
Jim
<a href="index.php?s=about" target="_self">About</a>
<a href="index.php?s=contact" target="_self">Contact</a> Note: It is a very bad idea to pass paths within the URL as your website could easily be XSS'ed, hence why I have used key words.
Now, within your content area, you want something like the following,
if (isset ($_GET['s'])) {
switch ($_GET['s']) {
case "about":
require_once ("some/sectioncontent.php");
break;
case "content":
require_once ("some/sectioncontent.php");
break;
default
// Error 404
break;
}
} else {
// Error 404
}
<snip>
Thanks
Jim
[edited by: dreamcatcher at 7:56 am (utc) on July 27, 2008]
[edit reason] No urls please! [/edit]