Either my if or my variables are messed up
<p>I recently just started playing around in PHP and got myself a small project/homework.<br>
The idea is very simple - by getting a number by user input, draw a circle.</p>

<p>I got the circle working with imagearc, everything scales beautiful by the number the user type in.<br>
However, there seems to be a color problem. On my main page, I created four radio buttons with 4 different colors. The radio button choose what color the circle has.<br>
I can't get it work though. The circle is not displaying anymore, even though I checked everything. Here's the code I try to use:</p>

<pre><code>&lt;form method="post" action="circle.php"&gt;
&lt;input type="radio" name="color" value="blue" class="color"&gt;Blue&lt;br /&gt;
&lt;input type="radio" name="color" value="red" class="color"&gt;Red&lt;br /&gt;
&lt;input type="radio" name="color" value="green" class="color"&gt;Green&lt;br /&gt;
&lt;input type="radio" name="color" value="yellow" class="color"&gt;Yellow&lt;br /&gt;
&lt;input type="submit" value="Send" name="submit" /&gt;
&lt;/form&gt;
</code></pre>

<p>That's from index.php, here's what I try to do</p>

<pre><code>$color = $_POST['color'];

if ($color == 'red') {
    $superColor = $red;
    }

// make some color
$white  = imagecolorallocate($img, 255, 255, 255);
$red    = imagecolorallocate($img, 255, 0, 0);

// draw the circle
imagearc($img, ($height + 10) / 2, ($width + 10) / 2, $circumference, $circumference, 0, 360, $superColor);
</code></pre>

<p>I'm still new, and still learning, so I guess there's an easier and prettier way of doing it. This is just my try. What am I doing wrong here?</p>

<p>Thanks in advance</p>

<p>EDIT: Thanks for the quick answers! I have tried what you guys (or girls) told me to do, change from ID to name and put the == 'red' in quotes - it doesn't work though.<br>
I think it has something to do with my if statement. Shouldn't it be possible to give the information stored in $red to $superColor by doing a simple $superColor = $red?<br>
If not, what should I do instead? Nothing shows up in my imagearc, if I change $superColor to $red, it shows up a nice, red circle.</p>

<p>An echo test shows that $_POST['color']; works just fine</p>
