Loading ...
Sorry, an error occurred while loading the content.

script tag in a JSON feed?

Expand Messages
  • osirisdf
    Hello, I have a slight problem, an adequate explanation of which I have not been able to find. I m hoping you can shed some light on the matter... I m trying
    Message 1 of 1 , Apr 1, 2008
    • 0 Attachment
      Hello,

      I have a slight problem, an adequate explanation of which I have not
      been able to find. I'm hoping you can shed some light on the matter...

      I'm trying to place product data from a JSON feed, and there's a
      "description" element as part of it. The content of that element is
      HTML, and includes a script tag, like so:

      {"...":"...","...:":"...","des":"<script type=\"text/javascript\"
      src=\"http://content.webservicecompany.net/companyname/service-
      name\"></script><br>The
      V1003 digital camera ... ","...":"..."}

      When I invoke the function that parses the JSON, and build the dynamic
      HTML content, the page is redirected to the URL in the src attribute
      of the inline script tag.


      Any light you can shed on this phenomenon and potential solutions
      would be greatly appreciated.



      Many thanks,

      osirisdf
    Your message has been successfully submitted and would be delivered to recipients shortly.