Freemarker insert String into Javascript code -


i know how can insert string javascript code in example below:

     <script type="application/ld+json">         {           "@context": "http://schema.org",           "@type": "restaurant",           "name": "dave's steak house",           "address": {             "@type": "postaladdress",             "streetaddress": "148 w 51st st",             "addresslocality": "new york",             "addressregion": "ny",             "postalcode": "10019",             "addresscountry": "us"           }         }         </script> 

the problem when try insert string between js appears interpreted html code %, &20 etc. have tried ?html, escape, no escape, ?string, ?js_string, etc.

that's string:

 {           "@context": "http://schema.org",           "@type": "restaurant",           "name": "dave's steak house",           "address": {             "@type": "postaladdress",             "streetaddress": "148 w 51st st",             "addresslocality": "new york",             "addressregion": "ny",             "postalcode": "10019",             "addresscountry": "us"           }         } 

and code:

${mystring}


Comments

Popular posts from this blog

testing - Detect whether test has failed within fixture -

Android: SharingActionView on swipe from bottom -

AbotX : How do you create a parallel crawler that stays on and can be added to at run time from new requests -