how to fix the SyntaxError: unterminated string literal when embed php in javascript? -


when try this:

var app_app = <?=$app_app?>; 

i got error:

syntaxerror: unterminated string literal var app_app = '<br /> 

strange, can me ?

var app_app = "<?php echo $app_app; ?>"; 

note: have echo out php variable define javascript , wrap inside quotes


Comments

Popular posts from this blog

Capture and play voice with Asterisk ARI -

visual studio - Installing Packages through Nuget - "Central Directory corrupt" -

java - Why database contraints in HSQLDB are only checked during a commit when using transactions in Hibernate? -