Extra caution is recommended when installing recently uploaded/updated scripts (read more)
Be sure you trust any scripts you install
Link Accoutrements
Append a small icon to mailto, PDF, doc, xls, & ppt links
Append a small icon to mailto, PDF, doc, xls, & ppt links.
This is based off of b10m's Link Warning script and utilizing the free icons from famfamfam.
updated 10.01.2006. case insensitive matching. improved styling. email icon not placed when link text is email address or says email.
updated 10.17.2006. icon not placed if img is inside the link.
note 11.28.2006. I likely won't be updating this script again. I'm now using the firefox extension Link Alert to accomplish the same feat. I suggest you check it out. (And of course, play with my code all you like)
|
|
@az1d:
|
|
|
Great script. I used the original for ages but find this much better. Any chance you can update this script so that it only picks up on .pdf .doc etc, rather than without the dot, cause I get a lot of false positives. Thanks for the recommendation of the similar extension, unfortunately I tend to click without hovering. |
|
|
Love it, very cool! |
|
|
I made a prepending one: http://userscripts.org/scripts/show/6539. Thanks for using Creative Commons. |
|
|
Nice work :) |
|
|
Thanks for the quick response Paul. It works as expected. |
|
|
Hi Michael. I updated the script to do this. If the lastChild of the link element is an IMG, it won't place an image. Hopefully that works nicely. Thanks for the feedback! |
|
|
Is it possible to not display the icons if the link element surrounds an image? For example, an author may have already added icons to their links and linked both the text and the icon. In this case your script will add an extra icon. |
|
|
Fantastic! |
You could comment on this script if you were logged in.
