Changeset 24359

Show
Ignore:
Timestamp:
11/20/08 01:06:51 (4 years ago)
Author:
suVene
Message:

mod siteinfo attribute

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/javascript/vimperator-plugins/branches/1.2/multi_requester.js

    r24355 r24359  
    3636 *           name:        'ex',                             // required 
    3737 *           description: 'example',                        // required 
    38  *           url:         'http://example.com/%s',          // required, %s <-- replace string 
    39  *           resultXpath: '//*',                            // optional(default all) 
     38 *           url:         'http://example.com/?%s',         // required, %s <-- replace string 
     39 *           xpath:      '//*',                            // optional(default all) 
    4040 *           srcEncode:   'SHIFT_JIS',                      // optional(default UTF-8) 
    4141 *           urlEncode:   'SHIFT_JIS',                      // optional(default srcEncode) 
     
    7474        description: 'SPACE ALC (\u82F1\u8F9E\u6717 on the Web)', 
    7575        url:         'http://eow.alc.co.jp/%s/UTF-8/', 
    76         resultXpath: 'id("resultList")' 
     76        xpath:      'id("resultList")' 
    7777     }, 
    7878     { 
     
    8080        description: 'goo \u8F9E\u66F8', 
    8181        url:         'http://dictionary.goo.ne.jp/search.php?MT=%s&kind=all&mode=0&IE=UTF-8', 
    82         resultXpath: 'id("incontents")/*[@class="ch04" or @class="fs14" or contains(@class, "diclst")]', 
     82        xpath:      'id("incontents")/*[@class="ch04" or @class="fs14" or contains(@class, "diclst")]', 
    8383        srcEncode:   'EUC-JP', 
    8484        urlEncode:   'UTF-8' 
     
    537537            url = res.request.url; 
    538538            escapedUrl = liberator.util.escapeHTML(url); 
    539             xpath = res.request.options.siteinfo.resultXpath; 
     539            xpath = res.request.options.siteinfo.xpath; 
    540540            doc = res.getHTMLDocument(xpath); 
    541541            if (!doc) throw 'XPath result is undefined or null.: XPath -> ' + xpath;