Skip to content

Conversation

@jgirault
Copy link

@jgirault jgirault commented Aug 2, 2012

While IE doesn't support textContent and Firefox doesn't support innerHTML, Chrome supports both but doesn't handle the same each method.

I got a bug in Chrome due to Ripple extension that adds some javascript on top of the iframe content.
Thus:
root.textContent will not escape the javascript
root.innerText will escape the javascript

So I suggest to prioritize innerText.

@tony2nite
Copy link

This also fixed an issue I had in Chrome with the Google Analytics Opt-out add-on

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants