no title [bookmarklet]

  • // ==UserScript==
    // @name        Hatena Bookmark Link
    // @namespace   massann
    // @description Add a link the tweet page to add Hatena Bookmark.https回避用greasemonkeyスクリプト。歯車アイコンの下の方が良かったかも
    // @include     https://twitter.com/*/status/*
    // @version     1
    // @grant       none
    // ==/UserScript==
    (function() {
      var data = 'data:image/gif;base64,'+
             'R0lGODlhIAAgAKIEAFJ55////ypfyYWl+v///wAAAAAAAAAAACH5BAEAAAQALAAAAAAgACAAAAOb'+
             'SLrc/jDKOaq9OGMAmP5gxXkDZ55oegoCqb4w68L02i5irct4iQbAoPDFU+ROwmSAeDP6kEEoMFUk'+
             'HE1DbBRVvXKy361tJl1qp9ym9XlWik1ddtj95sRT4Pa4h68D8nc/foBqXn+Db4FlfWh2hXKHjXpw'+
             'j4x0ZntOlnRUlTo1ip9MZKIqoaVpDI4srK2ur62qALC0tVUTuLm6uAkAOw==';
      var newLink = document.createElement('a');
      newLink.setAttribute('href', 'http://b.hatena.ne.jp/add?mode=confirm&title='+escape(document.title)+'&url='+escape(location.href));
      var icon = document.createElement('img');
      icon.setAttribute('src', data);
      newLink.appendChild(icon);
      var newDiv = document.createElement('div');
      newDiv.appendChild(newLink);
      var elements = document.getElementsByClassName('ProfileTweet-action ProfileTweet-action--reply');
      elements[0].parentNode.appendChild(newDiv);
    })();
  • Permalink
    このページへの個別リンクです。
    RAW
    書かれたコードへの直接のリンクです。
    Packed
    文字列が圧縮された書かれたコードへのリンクです。
    Userscript
    Greasemonkey 等で利用する場合の .user.js へのリンクです。
    Loader
    @require やソースコードが長い場合に多段ロードする Loader コミのコードへのリンクです。
    Metadata
    コード中にコメントで @xxx と書かれたメタデータの JSON です。

History

  1. 2015/10/20 08:08:58 - 2015-10-20
  2. 2015/10/20 07:34:20 - 2015-10-20