Home >Web Front-end >JS Tutorial >Double quotation mark conversion problem embedded in jsp (html) code in js - the event does not respond
The following is a piece of code that encountered a problem today. The onchange event is written in the select. Without escaping, the code parsed by F12 is messed up. The double quotes are inconsistent with what is written in the content, and there are spaces. Appeared. After a period of exploration, I found that it is enough to add escape where the error occurred (mainly in front of the quotation marks). The following is a useful code for reference.
"
The above is the detailed content of Double quotation mark conversion problem embedded in jsp (html) code in js - the event does not respond. For more information, please follow other related articles on the PHP Chinese website!