Skip to content

Instantly share code, notes, and snippets.

@montyr75
Last active January 2, 2016 04:09
Show Gist options
  • Save montyr75/8248296 to your computer and use it in GitHub Desktop.
Save montyr75/8248296 to your computer and use it in GitHub Desktop.
Prevent the user from dragging images on the page.
/* specific way */
img {
-moz-user-drag: -moz-none;
-webkit-user-drag: none;
user-drag: none;
}
/* "nuke 'em all" way */
img {
pointer-events: none;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment