Because of a single quote I am receiving a expecting ) after argument list error:
window.top.stopAudioUpload(1, '43', 'Thorne, Grandma's Goodbye excerpt.m4a');
audioupload.php (line 11, col 54)
My question is how can I get the line of code to accept single quote?
Code:
<script language="javascript" type="text/javascript">
window.top.stopAudioUpload(<?php echo $result; ?>, '<?php echo $id; ?>', '<?php echo $_FILES['fileAudio']['name'] ?>');
</script>
Try this:
Note the lack of quotes – this is important, because
json_encodewill add these automatically if needed.