Wouldn’t allowing users to input xhtml manually create the exact problem removing innerHTML was supposed to solve?
Wouldn’t allowing users to input xhtml manually create the exact problem removing innerHTML was
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Because pretend, etc. does not touch
innerHTML. With those, jQuery is converting your text to DOM nodes and adding them to the page using thechildNodearrays and other features.EDIT: Whoops, never mind, my mistake. It does use innerHTML to parse the html. The only difference is that the innerHTML of the target isn’t directly modified because when you feed the selector function html, it creates a new node and doesn’t directly modify the target’s innerHTML. Thanks, Esailija.