Changeset 591


Ignore:
Timestamp:
1999-09-16T15:16:01+12:00 (25 years ago)
Author:
sjboddie
Message:

Fixed up some of the chinese stuff

Location:
trunk/gsdl/macros
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/macros/pref.dm

    r548 r591  
    2929    savedhrefs = new Object();
    3030
    31     k\_arg = "";
    32     s\_arg = "";       
    33     m\_arg = "";
    34     o\_arg = "";
    35     b\_arg = "";
     31    argk = "";
     32    args = "";     
     33    argm = "";
     34    argo = "";
     35    argb = "";
    3636
    3737    function initialize () \{
     
    4040    \}
    4141
    42     function update\_hrefs () \{
     42    function updatehrefs () \{
    4343        for (i = 0; i < document.links.length; i++)
    44             document.links[i].href = savedhrefs[i] + k\_arg + s\_arg + m\_arg + o\_arg + b\_arg;
    45     \}
    46 
    47     function k\_update (value) \{
    48         if (value != _cgiargk_) k\_arg = "&k=" + value;
    49         else k\_arg = "";
    50         update\_hrefs();
    51     \}
    52 
    53     function s\_update (value) \{
    54         if (value != _cgiargs_) s\_arg = "&s=" + value;
    55         else s\_arg = "";
    56         update\_hrefs();
    57     \}
    58 
    59     function m\_update () \{
     44            document.links[i].href = savedhrefs[i] + argk + args + argm + argo + argb;
     45    \}
     46
     47    function updatek (value) \{
     48        if (value != _cgiargk_) argk = "&k=" + value;
     49        else argk = "";
     50        updatehrefs();
     51    \}
     52
     53    function updates (value) \{
     54        if (value != _cgiargs_) args = "&s=" + value;
     55        else args = "";
     56        updatehrefs();
     57    \}
     58
     59    function updatem () \{
    6060        value = document.PrefForm.m.options[document.PrefForm.m.selectedIndex].value;
    61         if (value != _cgiargm_) m\_arg = "&r=1&m=" + value;
    62         else m\_arg = "";
    63         update\_hrefs();
    64     \}
    65 
    66     function o\_update () \{
     61        if (value != _cgiargm_) argm = "&r=1&m=" + value;
     62        else argm = "";
     63        updatehrefs();
     64    \}
     65
     66    function updateo () \{
    6767        value = document.PrefForm.o.options[document.PrefForm.o.selectedIndex].value;
    68         if (value != _cgiargo_) o\_arg = "&r=1&o=" + value;
    69         else o\_arg = "";
    70         update\_hrefs();
    71     \}
    72 
    73     function b\_update (value) \{
    74         if (value != _cgiargb_) b\_arg = "&b=" + value;
    75         else b\_arg = "";
    76         update\_hrefs();
    77     \}
    78 
    79     function l\_update () \{
     68        if (value != _cgiargo_) argo = "&r=1&o=" + value;
     69        else argo = "";
     70        updatehrefs();
     71    \}
     72
     73    function updateb (value) \{
     74        if (value != _cgiargb_) argb = "&b=" + value;
     75        else argb = "";
     76        updatehrefs();
     77    \}
     78
     79    function updatel () \{
    8080        value = document.PrefForm.l.options[document.PrefForm.l.selectedIndex].value;
    81         location.href = location.href + k\_arg + s\_arg + m\_arg + o\_arg + b\_arg + "&l=" + value;
    82     \}
    83 
    84     function v\_update () \{
     81        location.href = location.href + argk + args + argm + argo + argb + "&l=" + value;
     82    \}
     83
     84    function updatev () \{
    8585        value = document.PrefForm.v.options[document.PrefForm.v.selectedIndex].value;
    86         location.href = location.href + k\_arg + s\_arg + m\_arg + o\_arg + b\_arg + "&v=" + value;
    87     \}
     86        location.href = location.href + argk + args + argm + argo + argb + "&v=" + value;
     87    \}
     88
     89    function updatew () \{
     90        value = document.PrefForm.w.options[document.PrefForm.w.selectedIndex].value;
     91        location.href = location.href + argk + args + argm + argo + argb + "&nw=" + value;
     92    \}
     93
    8894}
    8995
     
    113119
    114120_caseoption_ {
    115 <input type=radio name=k value=1 onClick="k\_update(1);"
     121<input type=radio name=k value=1 onClick="updatek(1);"
    116122        _If_(_cgiargk_, checked)>_textignorecase_<br>
    117 <input type=radio name=k value=0 onClick="k\_update(0);"
     123<input type=radio name=k value=0 onClick="updatek(0);"
    118124        _If_(_cgiargk_,, checked)>_textmatchcase_
    119125}
    120126
    121127_stemoption_ {
    122 <input type=radio name=s value=1 onClick="s\_update(1);"
     128<input type=radio name=s value=1 onClick="updates(1);"
    123129        _If_(_cgiargs_, checked)>_textstem_<br>
    124 <input type=radio name=s value=0 onClick="s\_update(0);"
     130<input type=radio name=s value=0 onClick="updates(0);"
    125131        _If_(_cgiargs_,, checked)>_textnostem_
    126132}
    127133
    128134_maxdocoption_ {
    129 <select name="m" onChange="m\_update();">
     135<select name="m" onChange="updatem();">
    130136  <option value="50"_If_("_cgiargm_" eq "50", selected)>50
    131137  <option value="100"_If_("_cgiargm_" eq "100", selected)>100
     
    135141
    136142_hitsperpageoption_ {
    137 <select name="o" onChange="o\_update();">
     143<select name="o" onChange="updateo();">
    138144  <option value="10"_If_("_cgiargo_" eq "10", selected)>10 
    139145  <option value="20"_If_("_cgiargo_" eq "20", selected)>20
     
    144150
    145151_modeoption_ {
    146 <input type=radio name=b value=0 onClick="b\_update(0);"
     152<input type=radio name=b value=0 onClick="updateb(0);"
    147153        _If_(_cgiargb_,, checked)>_textsimplemode_<br>
    148 <input type=radio name=b value=1 onClick="b\_update(1);"
     154<input type=radio name=b value=1 onClick="updateb(1);"
    149155        _If_(_cgiargb_, checked)>_textadvancedmode_
    150156}
     
    152158_languageoption_ {
    153159_textlanguage_
    154 <select name="l" onChange="l\_update();">
     160<select name="l" onChange="updatel();">
    155161  <option value="en"_If_("_cgiargl_",, selected)_If_("_cgiargl_" eq "en", selected)>English
    156162  <option value="mi"_If_("_cgiargl_" eq "mi", selected)>Maori
     163  <option value="zh"_If_("_cgiargl_" eq "zh", selected)>Chinese
     164</select>
     165}
     166
     167_encodingoption_ {
     168_textencoding_
     169<select name="w" onChange="updatew();">
     170  <option value="w" _If_("_cgiargw_" eq "w",selected)>Western (ISO-8859-1)
     171  <option value="u" _If_("_cgiargw_" eq "u",selected)>UTF-8
     172  <option value="g" _If_("_cgiargw_" eq "g",selected)>GBK
    157173</select>
    158174}
     
    160176_formatoption_ {
    161177_textformat_
    162 <select name="v" onChange="v\_update();">
     178<select name="v" onChange="updatev();">
    163179  <option value="0"_If_("_cgiargv_" eq "0", selected)>Graphical
    164180  <option value="1"_If_("_cgiargv_" eq "1", selected)>Textual
     
    188204<p>
    189205_languageoption_
     206
     207<p>
     208_encodingoption_
    190209
    191210<p>
     
    227246_textprefop_ {Return up to _maxdocoption_ hits with _hitsperpageoption_ hits per page.}
    228247_textlanguage_ {Interface language: }
     248_textencoding_ {Encoding: }
    229249_textformat_ {Interface format: }
    230250_textsimplemode_ {simple query mode}
  • trunk/gsdl/macros/zhquery.dm

    r587 r591  
    1515šéƒš}
    1616
     17_textsimplesearch_[l=zh] {按 _If_(_hselection_, _hselection_)_If_(_jselection_,_textjselect_)_If_(_nselection_, in _nselection_ language)
     18查询åŒ
     19含 _querytypeselection_ 提问词的记圕}
    1720
    18 _queryform_[l=zh] {
    19 <form name=QueryForm method=get action="_gwcgi_">
    20 
    21 <input type=hidden name="a" value="q">
    22 <input type=hidden name="e" value="_compressedoptions_">
    23 <input type=hidden name="r" value="1">
    24 
    25 <center>
    26 <table><tr><td>
    27 <_font_>
    28 <nobr>
    29 æŒ‰ _indexselection_ 查询åŒ
    30 å« _querytypeselection_ 提问词的记圕<br>
    31 </nobr>
    32 </font>
    33 </td></tr><tr><td>
    34 <_font_>
    35 <nobr>
    36 <input type="text" name="q" value="_querystring_" size="50">
    37 <input type="submit" value="_textbeginsearch_" name="b">
    38 </nobr>
    39 </font>
    40 </td></tr></table>
    41 </center>
    42 </font>
    43 </form>
    44 }
    45 
     21# these can be the same until translation is done
     22_textadvancedsearch_[l=zh] {_textsimplesearch_}
Note: See TracChangeset for help on using the changeset viewer.