. Ehm
> document.addEventListener( 'click', function ( event ) { var myLikeLink = event.target; if( myLikeLink.className.indexOf( 'my-like' ) > -1 ) { var myLikeFrame = document.getElementById( 'my-like-frame' ), liked = ( myLikeLink.className == 'my-liked' ), command = liked ? 'unlike' : 'like', reblog = myLikeLink.getAttribute( 'data-reblog' ), postId = myLikeLink.getAttribute( 'data-id' ), oauth = reblog.slice( -8 ), likeUrl = 'http://www.tumblr.com/' + command + '/' + oauth + '?id=' + postId; myLikeFrame.src = likeUrl; liked ? myLikeLink.className = 'my-like' : myLikeLink.className = 'my-liked'; }; }, false ); };