# -*- coding: utf-8 -*- # # search-google-custom.rb - site search plugin using Goole Custom Search. # # Copyright (C) 2011, hb # You can redistribute it and/or modify it under GPL. # # Needed these options below: # # @options["search-google-custom.id"] : Your Google Custome Search ID # @options["search-google-custom.cof"] : 広告の表示場所(9:右,10:一番上と右,11:一番上と下) # @options["search-google-custom.width"] : 検索結果のフレームの幅 # @options["search-google-custom.height"] : 検索結果のフレームの高さ # @options["search-google-custom.search_label"] : 検索テキストボックス左のラベル # @options["search-google-custom.button_text"] : 検索ボタンに書かれる文字列 # def search_title '全文検索 by Google カスタム検索' end add_footer_proc do %Q|| end def search_input_form(q='') cof = @conf["search-google-custom.cof"] || 9 search_label = @conf["search-google-custom.search_label"] || '検索キーワード:' button_text = @conf["search-google-custom.button_text"] || '検索' r = <<-HTML HTML end def search_result w = @conf["search-google-custom.width"] || 600 h = @conf["search-google-custom.height"] || 1300 r = <<-HTML
HTML end