In my script, I am trying to set a variable based upon an entry from my SQL table. Here's two different lines of code I've tried, but neither of them seems to work:
Expand|Select|Wrap|Line Numbers
- var opt_a = ($_POST['<?php echo $row_rs_detail['option_a']; ?>']);
[PHP]var opt_a = <?php echo "$_POST[".$row_rs_detail['option_a']."]"; ?>;[/PHP]
This isn't working AND gives me an error.
I apologize in advance for being a javascript and php newbie... maybe I'm going about this the wrong way. Any suggestions?
Thanks in advance.