https://github.com/matthewcallis/jquery-linkup
Find and link text to a given URL in a given set of elements.
https://github.com/matthewcallis/jquery-linkup
Last synced: 11 days ago
JSON representation
Find and link text to a given URL in a given set of elements.
- Host: GitHub
- URL: https://github.com/matthewcallis/jquery-linkup
- Owner: MatthewCallis
- License: mit
- Created: 2012-02-11T19:08:19.000Z (over 14 years ago)
- Default Branch: master
- Last Pushed: 2013-08-02T21:55:22.000Z (almost 13 years ago)
- Last Synced: 2025-11-15T03:37:57.366Z (7 months ago)
- Language: JavaScript
- Homepage: http://superfamicom.org/
- Size: 58.6 KB
- Stars: 3
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.markdown
- License: LICENSE.txt
Awesome Lists containing this project
README
# LinkUp
I needed to link many strings to various URLs but I didn't want to have to continuously update the page or keep track of the URLs in the database, and in some cases I didn't want the text linked in the visible source.
## Examples
Find and link BSNES and byuu to the appropriate page.
```
$('p').linkup([
{ find: "BSNES", replace: 'http://byuu.org/bsnes/' },
{ find: /byuu(-san)?/, replace: 'http://byuu.org/' }
]);
```
Find and link SNES to the proper page, but don't link things in the black list.
```
$('div').linkup([
{ find: "SNES", replace: 'http://superfamicom.org/' }
], { blacklist: 'html,head,style,title,link,meta,script,object,embed,iframe,pre,a,h1,h2,h3' });
```
## Change Log
* 0.1.0: Initial Commit