"View img title-text on click in popup" bookmarklet

Things that don't belong anywhere else. (Check first).

Moderators: Moderators General, Prelates, Magistrates

User avatar
scikidus
Posts: 792
Joined: Wed Nov 26, 2008 9:34 pm UTC
Location: New York, NY
Contact:

"View img title-text on click in popup" bookmarklet

Postby scikidus » Sat Nov 27, 2010 11:08 pm UTC

I don't think this counts under Coding, as it's not discussing implementation, it's just a bookmarklet.

A quick-and-dirty bookmarklet which displays an images title text in a popup when the image is clicked. It helps me on my iTouch when I forget about m.xkcd.com or I'm on some other comic which uses the title text.

Code: Select all

javascript:imgs=document.images;for(i=0;i<imgs.length;i++){if(imgs[i].getAttribute('title')){imgs[i].setAttribute('onclick','javascript:alert(this.getAttribute(%22title%22));')}}void(0);


Hope someone else finds this helpful :)
Happy hollandaise!

"The universe is a figment of its own imagination" -Douglas Adams

Return to “General”

Who is online

Users browsing this forum: No registered users and 44 guests