Skip to content

Instantly share code, notes, and snippets.

@marwinious
Created September 24, 2013 20:41
Show Gist options
  • Select an option

  • Save marwinious/6690924 to your computer and use it in GitHub Desktop.

Select an option

Save marwinious/6690924 to your computer and use it in GitHub Desktop.
From http://stackoverflow.com/questions/15407907/jquery-css-important-change-css-on-click How to add "!important" as css using jquery. The "cssText" option is literal and should stay as-is. It's apparently a reserved word that tells jquery what to do.
$("#SomeElement").css("cssText", "height: 650px !important;");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment