Customize Google

From LemonWiki共筆
Revision as of 10:58, 8 June 2005 by Planetoid (talk | contribs)
Jump to navigation Jump to search

目的:

  • 在Google檢索結果的頁面提供其他連結到指定的檔案型態、Google Scholar與其他搜尋引擎


須事先安裝

  1. Mozilla FireFox
  2. 安裝擴充套件: mozdev.org - greasemonkey: index
  3. 設定 CustomizeGoogle.com 提供的script 選項
  4. 安裝 CustomizeGoogle.com 提供的script (在scipt輸出的頁面,點選 Firefox 工具 -> Install User Script)
  5. 將JS副檔名的開啟方式,指到你常用的文字編輯軟體, 例如Macromedia Dreamweaver等
  6. 視情況修改customizegoogle.user.js

以下是我的修改


// ==/UserScript==
(function() {
    var CustomizeGoogleServices = {
	_otherWebSearches: function(q) {
	    var s = '';
	    s += '<a href="http://www.google.com.tw/search?le=en&ie=UTF-8&oe=utf-8&q=' + q + '&btnG=Google+Search&num=20&sourceid=Mozilla-search&client=firefox-a&rls=org.mozilla:zh-TW:official&as_filetype=pdf">.PDF</a>, ';
	    s += '<a href="http://www.google.com.tw/search?le=en&ie=UTF-8&oe=utf-8&q=' + q + '&btnG=Google+Search&num=20&sourceid=Mozilla-search&client=firefox-a&rls=org.mozilla:zh-TW:official&as_filetype=ppt">.PPT</a>, ';
	    s += '<a href="http://scholar.google.com/scholar?q=' + q + '&ie=UTF-8&oe=UTF-8&hl=en&btnG=Search">Google Scholar</a>, ';
	    s += '<a href="http://search.yahoo.com/search?p=' + q + '&ei=UTF-8">Yahoo</a>, ';
	    s += '<a href="http://tw.search.yahoo.com/search?p=' + q + '&ei=UTF-8">YahooTW</a>, ';
	    s += '<a href="http://www.openfind.com.tw/cgi-bin/tw/webquery?query=' + q + '&Function=search&f=main&redirect=ON&type=image&ServiceID=0">Openfind</a>, ';
	    s += '<a href="http://web.ask.com/web?q=' + q + '">Ask Jeeves</a>, ';
//	    s += '<a href="http://www.alltheweb.com/search?q=' + q + '&cs=utf-8">AllTheWeb</a>, ';
	    s += '<a href="http://s.teoma.com/search?q=' + q + '">Teoma</a>, ';
	    s += '<a href="http://vivisimo.com/search?tb=homepage&query=' + q + '&v%3Asources=Web">Vivisimo</a>, ';		
//	    s += '<a href="http://search.msn.com/results.aspx?q=' + q + '">MSN</a>, ';
//	    s += '<a href="http://search.lycos.com/default.asp?query=' + q + '">Lycos</a>, ';
	    s += '<a href="http://www.technorati.com/cosmos/search.html?url=' + q + '">Technorati</a>, ';
	    s += '<a href="http://www.feedster.com/search.php?q=' + q + '">Feedster</a>, ';
	    s += '<a href="http://zniff.com/?s=' + q + '&meta=on">Zniff</a>, ';		
//	    s += '<a href="http://www.bloglines.com/search?t=1&q=' + q + '">Bloglines</a>, ';
//		s += '<a href="http://www.altavista.com/web/results?q=' + q + '">Altavista</a>'; 
	    return s;
	},

注意:因為Openfine需使用Big5編碼的中文,所以此處僅能使用英文字串進行搜尋。