Skip to content

Instantly share code, notes, and snippets.

@rhysburnie
Last active August 29, 2015 13:59
Show Gist options
  • Save rhysburnie/10944948 to your computer and use it in GitHub Desktop.
Save rhysburnie/10944948 to your computer and use it in GitHub Desktop.
Return filtered collection of external links
@rhysburnie
Copy link
Author

Only looks on href or src (if script tag)

EXAMPLE:

var external_links = $('a').externallinks();

For styling purposes obviously these days it's better to style via attribute selectors.
This can be useful for other js requirements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment