Create a gist now

Instantly share code, notes, and snippets.

OpenGraph Bookmarklet
javascript:$=jQuery;if(0!==$("#myogdiv").length)$("#myogdiv").hide().remove();else{var%20myogdiv=$('<div%20id="myogdiv"/>');$("body").append(myogdiv);$('head%20meta[property^="og:"],head%20meta[property^="fb:"],head%20meta[name^="twitter:"]').each(function(d,b){var%20a=$(b).attr("property"),c=$(b).attr("content");void%200==a&&(a=$(b).attr("name"));$(myogdiv).append("<div><b>"+a+":</b>"+c+"</div>");"og:image"==a&&$(myogdiv).append('<br/><img%20src="'+c+'"/>')});$(myogdiv).css("position","fixed").css("top","0").css("zIndex",99999).css("padding","0.5em").css("border","1px%20solid%20red").css("backgroundColor","white")}void(0);
@dougalcampbell

Updated to support Twitter Card info.

Note: depends on jQuery. If jQuery isn't already on the page, use the jQuerify Bookmarklet: http://www.learningjquery.com/2009/04/better-stronger-safer-jquerify-bookmarklet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment