This is really starting to get me mad... I've tried everything.
Here's a simplified example of what I'm trying to do:
$mydata = array('0'=>'somedata', '1'=>'somemoredata', '2'=>'againdata');
//Say I'm getting 0, 1 or 2 from a form on the previous page:
$a = $_POST['number'];
//Then depending on the value of $a, I want to access the data in the array
echo $mydata['$a'];
The trouble is that I know I'm doing something wrong with that last lign, I just don't know what the syntax is!
Please help.
Thanks,
Alex