Skip to content

Instantly share code, notes, and snippets.

@tevashov
Last active October 27, 2022 21:52
Show Gist options
  • Select an option

  • Save tevashov/5172445 to your computer and use it in GitHub Desktop.

Select an option

Save tevashov/5172445 to your computer and use it in GitHub Desktop.
Access elements with IDs containing special characters #jQuery
$("$some[id]").show(); // won't work for this type of ID
$("$some\\[id\\]").show() // works fine for the ID: some[id]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment