view rakuten-books-direct-search.user.js @ 53:28fde586a234

Add twitter anti-crap (part 1)
author nanaya <me@nanaya.pro>
date Sat, 30 Jun 2018 21:50:51 +0900
parents 2e1cae72a63e
children 09f735548b2c
line wrap: on
line source

// ==UserScript==
// @name         rakuten books direct search
// @namespace    https://myconan.net
// @version      1.0.2
// @description  Search on rakuten without tracking proxy
// @author       nanaya
// @match        https://books.rakuten.co.jp/*
// @match        http://books.rakuten.co.jp/*
// @match        https://*.books.rakuten.co.jp/*
// @match        http://*.books.rakuten.co.jp/*
// @grant        none
// @downloadURL  https://bitbucket.org/!api/2.0/snippets/nanayapro/TK64/tip/files/rakuten-books-direct-search.user.js
// ==/UserScript==

;(function() {
  var $ = jQuery;
  var $form = $("form[name='srchFrm']");

  if (!$form.length) { return; }
  
  var searchUrl = $form.find("input[name='R2']").attr("value");
  $form.attr("action", searchUrl);
}).call();