I currently am facing a problem I have asked a knowledgable PHP user who is stumped as well, regarding a simple PHP navigation...
if(!is_null($_GET['id'])) {
$filename = $_GET['id'].".php";
if(file_exists($filename)) {
require_once("$filename");
} else {
echo "<p>The page <strong>\"".$_GET['id']."\"</strong> that you requested does not exist on this server!</p>";
}
} else {
require_once("main.php");
}
-The above code is implemented in the 'content' section of my website. When I tested to see if the navigation worked typing this into the browser: http://www.mysite.com/index.php?id=main, it worked. However and more importantly, my issue is that I cannot implement a floodbox php file into my site when I link text on my left navigation menu to the 'content' area.
-I created a shoutbox.php file which only contains:
include("shoutbox/floodbox.php");
-When I created a link to open up the floodbox in the 'content' section, I put http://www.mysite.com/index.php?id=shoutbox , which of course would 'include' the floodbox file... I receive an error that says "can't open file"
If anyone can help me out I would appreciate it, and if you need more information that I may have left out, please let me know. Thanks