Amazon.co.jpで著者検索(絞り込み)

    
      
  • /*
     * @title Amazon.co.jpで著者検索(絞り込み)
     * @description 著者名を指定してやるとAmazon.co.jpで著者検索を実行・参照:https://twitter.com/furyutei/status/534193939054477312
     * @include *
     * @license MIT License
     * @javascript_url
     */
    
    (function(author, base, author2){
    if (!author) return;
    author = author.replace(/(?:^\s+|\s+$)/g, '');
    author2 = author.replace(/\s+/g, ' ');
    author = author.replace(/\s+/g, '');
    var link=document.createElement('a');
    link.target = '_blank';
    link.style = 'display:none;';
    link.href = base.replace(/#AUTHOR#/g, encodeURIComponent(author)+(author==author2?'':',p_lbr_three_browse-bin:'+encodeURIComponent(author2)));
    document.documentElement.appendChild(link);
    link.click();
    link.parentNode.removeChild(link);
    })(String(document.getSelection())||prompt('\u8457\u8005\u540d',''), 'http://www.amazon.co.jp/s?ie=UTF8&page=1&rh=n%3A465392%2Cp_27%3A#AUTHOR#&sort=date-desc-rank&unfiltered=1')
  • Permalink
    このページへの個別リンクです。
    RAW
    書かれたコードへの直接のリンクです。
    Packed
    文字列が圧縮された書かれたコードへのリンクです。
    Userscript
    Greasemonkey 等で利用する場合の .user.js へのリンクです。
    Loader
    @require やソースコードが長い場合に多段ロードする Loader コミのコードへのリンクです。
    Metadata
    コード中にコメントで @xxx と書かれたメタデータの JSON です。

History

  1. 2014/11/17 20:40:50 - 2014-11-17