Skip to content

Instantly share code, notes, and snippets.

@smugen
Created July 10, 2012 06:55
Show Gist options
  • Select an option

  • Save smugen/3081674 to your computer and use it in GitHub Desktop.

Select an option

Save smugen/3081674 to your computer and use it in GitHub Desktop.
obtain the max resolution of picasa url
(function () {
var hiresurl,
hiresimg;
hiresurl = function hiresurl (source) { return source.replace(/\/s\d+\//i, "/s0/"); };
hiresimg = function hiresimg (){
var imgs = document.getElementsByTagName("img"),
len = imgs.length,
img;
for (var i = len-1; i+1; i--) {
img = imgs[i];
img.src = hiresurl(img.src);
}
};
hiresimg();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment