1

I get my iframeurl using request.getAttribute and I loaded directly in to the body by <%= iframeurl %> but this doesn't work in Chrome. working fine in Firefox. if I gave directly the iframe URL in JSP it is working in Chrome!

What's the problem? Could anybody help me?

1
  • i gave like below<body> <% String iframeurl; url=(String)request.getAttribute("iframeurl"); %> <%= iframeurl %> </body>
    – udhaya
    Dec 27, 2011 at 9:52

1 Answer 1

3

This is a security feature of Chrome to prevent cross site scripting (XSS) attacks. When the iframe src url is posted in the http request you will not be able to use it in an iframe without applying a special header to the receiving page: X-XSS-Protection: 0

You could also avoid sending the iframe element in the post, and instead just send the src url.

See also: Refused to execute a JavaScript script. Source code of script found within request

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.