Beginning PHP (loading DIV)
<p>I'm just diving into PHP and have been doing some reading and playing around - with my code below, I'm trying to load the pages (as you can see) - I'm getting parse error. Syntax error, unexpecter T_VARIABLE in index.php on line 7</p>

<p>Line 7 on my index</p>

<pre><code>&lt;?php include(''$id'') ?&gt;
</code></pre>

<p>I'm told is supposed to be for variables rather than ('$id')</p>

<p>When I use ('$id') or ('$nav_menu') as is in the current coding, it gives me failed to open stream: No such file or directory</p>

<p>I'm probably missing something blatantly obvious, but can someone point me in the right direction?</p>

<p>Thanks</p>

<pre><code>&lt;?php
if (is_numeric($_GET['id'])) //prevent hacking
{
switch ($_GET['id']) //get the id of menu needed for this page
{
case 0:
    $nav_menu = "content.php"; //if the variable is 0 or not set
    break;
case 1:
    $nav_menu = "bio.php"; //if the variable is 1, get category 1 links
    break;
case 2:
    $nav_menu = "contact.php"; //if the variable is 2, get category 2 links
    break;
default:
    $nav_menu = "content.php"; //redundant for defaulting if the id is greater than 2
}
}
?&gt;
</code></pre>
