Accessing elements with IDs containing special characters


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. $("$some[id]").show(); // won't work for this type of ID
  2. $("$some\\[id\\]").show() // works fine for the ID: some[id]
  3.  

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.