View on GitHub

GuardianCaptioner

Saw this tweet on @GuardianTT's feed: " Check out today’s Talk of Trinidad photoblog. http://ht.ly/iCwsP . Click any photo to see the caption." and I thought better could be done.

Download this project as a .zip file Download this project as a tar.gz file

GuardianCaptioner

so, if you make a bookmarklet using the captioner.js contents, it will display captions.

You should see a caption for every photo you hover over in the gallery.

How to make it work (easy as pie):

  1. Drag this button to our favorites/bookmarks of your browser: Guardian Captioner
  2. Go to the Trinidad Guardian photoblog you want to try this on, say, this one.
  3. Click on the bookmark you just created.

You should see a caption for every photo you hover over in the gallery.

How to make it work (technical way):

  1. Go to a Trinidad Guardian photoblog, like, http://www.guardian.co.tt/gallery/talk-trinidad-09-march-2013?utm_source=iStarr&utm_medium=github&utm_campaign=innovation
  2. Clear the address bar
  3. Type javascript:
  4. Copy/paste this script command (function(){ s=document.createElement('SCRIPT'); s.type='text/javascript'; s.src='https://raw.github.com/irwinwilliams/GuardianCaptioner/master/captioner.min.js'; document.getElementsByTagName('head')[0].appendChild(s); })();

so that your browser's address bar reads: javascript:(function(){ s=document.createElement('SCRIPT'); s.type='text/javascript'; s.src='http://irwinwilliams.github.com/GuardianCaptioner/javascripts/captioner.public.js?'; document.getElementsByTagName('head')[0].appendChild(s); })();

You should see a caption for every photo you hover over in the gallery.