First timer here, and total noob when it comes to PHP and JavaScript.
I have 2 lines of code which are identical, however one works and one kicks out a unterminated string literal error.
One that works:
<script type="text/javascript">
document.getElementById('vehiclemake').value
= "<?php echo $_POST['vehiclemake'];?>";
</script>
One that doesn't:
<script>
document.getElementById('PostcodeSelect').value =
"<?php echo $_POST['PostcodeSelect'];?>";
</script>
The only thing I can think of is that the postcode select POST variable has an underscore in it eg: AB1_1BA does this need escaping or something?
Any help greatly appreciated, cheers!