Skip to content

Instantly share code, notes, and snippets.

@atri-konami
Last active May 23, 2016 10:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save atri-konami/74e785f53cbecb8f085cf1b2691e50d5 to your computer and use it in GitHub Desktop.
Save atri-konami/74e785f53cbecb8f085cf1b2691e50d5 to your computer and use it in GitHub Desktop.
Google Play MusicのNowPlayngをツイートするBookmarklet
!function(){var e=document.querySelector("#currently-playing-title").innerHTML,t=document.querySelector("#player-artist").innerHTML,n=document.querySelector(".player-album").innerHTML,o=encodeURIComponent("Now playing on Google Play Music: "+e+" - "+t+" in "+n);window.open("https://twitter.com/intent/tweet?text="+o+"&hashtags=NowPlaying","","width=550, height=420")}();
(function(){
var song = document.querySelector("#currently-playing-title").innerHTML;
var artist = document.querySelector("#player-artist").innerHTML;
var album = document.querySelector(".player-album").innerHTML;
var text = encodeURIComponent("Now playing on Google Play Music: " + song + " - " + artist + " in " + album);
window.open('https://twitter.com/intent/tweet?text=' + text + '&hashtags=NowPlaying', '', 'width=550, height=420');
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment