Ignore:
Timestamp:
2011/03/09 14:55:25 (15 years ago)
Author:
Seasoft
Message:

#627(ソース整形・ソースコメントの改善)

  • TAB
  • インデント

#624(軽微な表示乱れを修正)

  • HTML 構文誤り
  • CSS 構文誤り
Location:
branches/version-2_5-dev/html/js
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_5-dev/html/js/css.js

    r20116 r20566  
    2020 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. 
    2121 */ 
    22  gCssUA = navigator.userAgent.toUpperCase(); 
     22gCssUA = navigator.userAgent.toUpperCase(); 
    2323gCssBrw = navigator.appName.toUpperCase(); 
    2424 
    2525with (document) { 
    26         write("<style type=\"text/css\"><!--"); 
     26    write("<style type=\"text/css\"><!--"); 
    2727 
     28    //WIN-IE 
     29    if (gCssUA.indexOf("WIN") != -1 && gCssUA.indexOf("MSIE") != -1) { 
     30        write(".fs10 {font-size: 62.5%; line-height: 150%; letter-spacing:1px;}"); 
     31        write(".fs12 {font-size: 75%; line-height: 150%; letter-spacing:1.5px;}"); 
     32        write(".fs14 {font-size: 87.5%; line-height: 150%; letter-spacing:2px;}"); 
     33        write(".fs18 {font-size: 117.5%; line-height: 130%; letter-spacing:2.5px;}"); 
     34        write(".fs22 {font-size: 137.5%; line-height: 130%; letter-spacing:3px;}"); 
     35        write(".fs24 {font-size: 150%; line-height: 130%; letter-spacing:3px;}"); 
     36        write(".fs30 {font-size: 187.5%; line-height: 125%; letter-spacing:3.5px;}"); 
     37        write(".fs10n {font-size: 62.5%; letter-spacing:1px;}"); 
     38        write(".fs12n {font-size: 75%; letter-spacing:1.5px;}"); 
     39        write(".fs14n {font-size: 87.5%; letter-spacing:2px;}"); 
     40        write(".fs18n {font-size: 117.5%; letter-spacing:2.5px;}"); 
     41        write(".fs22n {font-size: 137.5%; letter-spacing:1px;}"); 
     42        write(".fs24n {font-size: 150%; letter-spacing:1px;}"); 
     43        write(".fs30n {font-size: 187.5%; letter-spacing:1px;}"); 
     44        write(".fs12st {font-size: 75%; line-height: 150%; letter-spacing:1.5px; font-weight: bold;}"); 
     45    } 
    2846 
    29 //WIN-IE 
    30     if (gCssUA.indexOf("WIN") != -1 && gCssUA.indexOf("MSIE") != -1) { 
    31         write(".fs10 {font-size: 62.5%; line-height: 150%; letter-spacing:1px;}"); 
    32         write(".fs12 {font-size: 75%; line-height: 150%; letter-spacing:1.5px;}"); 
    33         write(".fs14 {font-size: 87.5%; line-height: 150%; letter-spacing:2px;}"); 
    34         write(".fs18 {font-size: 117.5%; line-height: 130%; letter-spacing:2.5px;}"); 
    35         write(".fs22 {font-size: 137.5%; line-height: 130%; letter-spacing:3px;}"); 
    36         write(".fs24 {font-size: 150%; line-height: 130%; letter-spacing:3px;}"); 
    37         write(".fs30 {font-size: 187.5%; line-height: 125%; letter-spacing:3.5px;}"); 
    38         write(".fs10n {font-size: 62.5%; letter-spacing:1px;}"); 
    39         write(".fs12n {font-size: 75%; letter-spacing:1.5px;}"); 
    40         write(".fs14n {font-size: 87.5%; letter-spacing:2px;}"); 
    41         write(".fs18n {font-size: 117.5%; letter-spacing:2.5px;}"); 
    42         write(".fs22n {font-size: 137.5%; letter-spacing:1px;}"); 
    43         write(".fs24n {font-size: 150%; letter-spacing:1px;}"); 
    44         write(".fs30n {font-size: 187.5%; letter-spacing:1px;}"); 
    45         write(".fs12st {font-size: 75%; line-height: 150%; letter-spacing:1.5px; font-weight: bold;}"); 
    46     } 
     47    //WIN-NN 
     48    if (gCssUA.indexOf("WIN") != -1 && gCssBrw.indexOf("NETSCAPE") != -1) { 
     49        write(".fs10 {font-size:72%; line-height:130%;}"); 
     50        write(".fs12 {font-size: 75%; line-height: 150%;}"); 
     51        write(".fs14 {font-size: 87.5%; line-height: 140%;}"); 
     52        write(".fs18 {font-size: 117.5%; line-height: 130%;}"); 
     53        write(".fs22 {font-size: 137.5%; line-height: 130%;}"); 
     54        write(".fs24 {font-size: 150%; line-height: 130%;}"); 
     55        write(".fs30 {font-size: 187.5%; line-height: 120%;}"); 
     56        write(".fs10n {font-size:72%;}"); 
     57        write(".fs12n {font-size: 75%;}"); 
     58        write(".fs14n {font-size: 87.5%;}"); 
     59        write(".fs18n {font-size: 117.5%;}"); 
     60        write(".fs22n {font-size: 137.5%;}"); 
     61        write(".fs24n {font-size: 150%;}"); 
     62        write(".fs30n {font-size: 187.5%;}"); 
     63        write(".fs12st {font-size: 75%; line-height: 150%; font-weight: bold;}"); 
     64    } 
    4765 
    48 //WIN-NN 
    49     if (gCssUA.indexOf("WIN") != -1 && gCssBrw.indexOf("NETSCAPE") != -1) { 
    50         write(".fs10 {font-size:72%; line-height:130%;}"); 
    51         write(".fs12 {font-size: 75%; line-height: 150%;}"); 
    52         write(".fs14 {font-size: 87.5%; line-height: 140%;}"); 
    53         write(".fs18 {font-size: 117.5%; line-height: 130%;}"); 
    54         write(".fs22 {font-size: 137.5%; line-height: 130%;}"); 
    55         write(".fs24 {font-size: 150%; line-height: 130%;}"); 
    56         write(".fs30 {font-size: 187.5%; line-height: 120%;}"); 
    57         write(".fs10n {font-size:72%;}"); 
    58         write(".fs12n {font-size: 75%;}"); 
    59         write(".fs14n {font-size: 87.5%;}"); 
    60         write(".fs18n {font-size: 117.5%;}"); 
    61         write(".fs22n {font-size: 137.5%;}"); 
    62         write(".fs24n {font-size: 150%;}"); 
    63         write(".fs30n {font-size: 187.5%;}"); 
    64         write(".fs12st {font-size: 75%; line-height: 150%; font-weight: bold;}"); 
    65     } 
     66    //WIN-NN4.x 
     67    if ( navigator.appName == "Netscape" && navigator.appVersion.substr(0,2) == "4." ) { 
     68        write(".fs10 {font-size:90%; line-height: 130%;}"); 
     69        write(".fs12 {font-size: 100%; line-height: 140%;}"); 
     70        write(".fs14 {font-size: 110%; line-height: 135%;}"); 
     71        write(".fs18 {font-size: 130%; line-height: 175%;}"); 
     72        write(".fs24 {font-size: 190%; line-height: 240%;}"); 
     73        write(".fs30 {font-size: 240%; line-height: 285%;}"); 
     74        write(".fs10n {font-size:90%;}"); 
     75        write(".fs12n {font-size: 100%;}"); 
     76        write(".fs14n {font-size: 110%;}"); 
     77        write(".fs18n {font-size: 130%;}"); 
     78        write(".fs24n {font-size: 190%;}"); 
     79        write(".fs30n {font-size: 240%;}"); 
     80        write(".fs12st {font-size: 100%; line-height: 140%; font-weight: bold;}"); 
     81    } 
    6682 
    67 //WIN-NN4.x 
    68     if ( navigator.appName == "Netscape" && navigator.appVersion.substr(0,2) == "4." ) { 
    69         write(".fs10 {font-size:90%; line-height: 130%;}"); 
    70         write(".fs12 {font-size: 100%; line-height: 140%;}"); 
    71         write(".fs14 {font-size: 110%; line-height: 135%;}"); 
    72         write(".fs18 {font-size: 130%; line-height: 175%;}"); 
    73         write(".fs24 {font-size: 190%; line-height: 240%;}"); 
    74         write(".fs30 {font-size: 240%; line-height: 285%;}"); 
    75         write(".fs10n {font-size:90%;}"); 
    76         write(".fs12n {font-size: 100%;}"); 
    77         write(".fs14n {font-size: 110%;}"); 
    78         write(".fs18n {font-size: 130%;}"); 
    79         write(".fs24n {font-size: 190%;}"); 
    80         write(".fs30n {font-size: 240%;}"); 
    81         write(".fs12st {font-size: 100%; line-height: 140%; font-weight: bold;}"); 
    82     } 
     83    //MAC 
     84    if (gCssUA.indexOf("MAC") != -1) { 
     85        write(".fs10 {font-size: 10px; line-height: 14px;}"); 
     86        write(".fs12 {font-size: 12px; line-height: 18px;}"); 
     87        write(".fs14 {font-size: 14px; line-height: 18px;}"); 
     88        write(".fs18 {font-size: 18px; line-height: 23px;}"); 
     89        write(".fs22 {font-size: 22px; line-height: 27px;}"); 
     90        write(".fs24 {font-size: 24px; line-height: 30px;}"); 
     91        write(".fs30 {font-size: 30px; line-height: 35px;}"); 
     92        write(".fs10n {font-size: 10px;}"); 
     93        write(".fs12n {font-size: 12px;}"); 
     94        write(".fs14n {font-size: 14px;}"); 
     95        write(".fs18n {font-size: 18px;}"); 
     96        write(".fs22n {font-size: 22px;}"); 
     97        write(".fs24n {font-size: 24px;}"); 
     98        write(".fs30n {font-size: 30px;}"); 
     99        write(".fs12st {font-size: 12px; line-height: 18px; font-weight: bold;}"); 
     100    } 
    83101 
    84 //MAC 
    85     if (gCssUA.indexOf("MAC") != -1) { 
    86         write(".fs10 {font-size: 10px; line-height: 14px;}"); 
    87         write(".fs12 {font-size: 12px; line-height: 18px;}"); 
    88         write(".fs14 {font-size: 14px; line-height: 18px;}"); 
    89         write(".fs18 {font-size: 18px; line-height: 23px;}"); 
    90         write(".fs22 {font-size: 22px; line-height: 27px;}"); 
    91         write(".fs24 {font-size: 24px; line-height: 30px;}"); 
    92         write(".fs30 {font-size: 30px; line-height: 35px;}"); 
    93         write(".fs10n {font-size: 10px;}"); 
    94         write(".fs12n {font-size: 12px;}"); 
    95         write(".fs14n {font-size: 14px;}"); 
    96         write(".fs18n {font-size: 18px;}"); 
    97         write(".fs22n {font-size: 22px;}"); 
    98         write(".fs24n {font-size: 24px;}"); 
    99         write(".fs30n {font-size: 30px;}"); 
    100         write(".fs12st {font-size: 12px; line-height: 18px; font-weight: bold;}"); 
    101     } 
    102  
    103     write("--></style>"); 
     102    write("--></style>"); 
    104103} 
  • branches/version-2_5-dev/html/js/site.js

    r20116 r20566  
    6767 
    6868function fnOpenNoMenu(URL) { 
    69     window.open(URL,"nomenu","scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no"); 
     69    window.open(URL,"nomenu","scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no"); 
    7070} 
    7171 
    7272function fnOpenWindow(URL,name,width,height) { 
    73     window.open(URL,name,"width="+width+",height="+height+",scrollbars=yes,resizable=no,toolbar=no,location=no,directories=no,status=no"); 
     73    window.open(URL,name,"width="+width+",height="+height+",scrollbars=yes,resizable=no,toolbar=no,location=no,directories=no,status=no"); 
    7474} 
    7575 
    7676function fnSetFocus(name) { 
    77     if(document.form1[name]) { 
    78         document.form1[name].focus(); 
    79     } 
     77    if(document.form1[name]) { 
     78        document.form1[name].focus(); 
     79    } 
    8080} 
    8181 
    8282// セレクトボックスに項目を割り当てる. 
    8383function fnSetSelect(name1, name2, val) { 
    84     sele1 = document.form1[name1]; 
    85     sele2 = document.form1[name2]; 
    86  
    87     if(sele1 && sele2) { 
    88         index=sele1.selectedIndex; 
    89  
    90         // セレクトボックスのクリア 
    91         count=sele2.options.length 
    92         for(i = count; i >= 0; i--) { 
    93             sele2.options[i]=null; 
    94         } 
    95  
    96         // セレクトボックスに値を割り当てる。 
    97         len = lists[index].length 
    98         for(i = 0; i < len; i++) { 
    99             sele2.options[i]=new Option(lists[index][i], vals[index][i]); 
    100             if(val != "" && vals[index][i] == val) { 
    101                 sele2.options[i].selected = true; 
    102             } 
    103         } 
    104     } 
     84    sele1 = document.form1[name1]; 
     85    sele2 = document.form1[name2]; 
     86 
     87    if(sele1 && sele2) { 
     88        index=sele1.selectedIndex; 
     89 
     90        // セレクトボックスのクリア 
     91        count=sele2.options.length 
     92        for(i = count; i >= 0; i--) { 
     93            sele2.options[i]=null; 
     94        } 
     95 
     96        // セレクトボックスに値を割り当てる。 
     97        len = lists[index].length 
     98        for(i = 0; i < len; i++) { 
     99            sele2.options[i]=new Option(lists[index][i], vals[index][i]); 
     100            if(val != "" && vals[index][i] == val) { 
     101                sele2.options[i].selected = true; 
     102            } 
     103        } 
     104    } 
    105105} 
    106106 
     
    108108function fnCancelEnter() 
    109109{ 
    110     if (gCssUA.indexOf("WIN") != -1 && gCssUA.indexOf("MSIE") != -1) { 
    111         if (window.event.keyCode == 13) 
    112         { 
    113             return false; 
    114         } 
    115     } 
    116     return true; 
     110    if (gCssUA.indexOf("WIN") != -1 && gCssUA.indexOf("MSIE") != -1) { 
     111        if (window.event.keyCode == 13) 
     112        { 
     113            return false; 
     114        } 
     115    } 
     116    return true; 
    117117} 
    118118 
    119119// モードとキーを指定してSUBMITを行う。 
    120120function fnModeSubmit(mode, keyname, keyid) { 
    121     switch(mode) { 
    122     case 'delete_category': 
    123         if(!window.confirm('選択したカテゴリとカテゴリ内のすべてのカテゴリを削除します')){ 
    124             return; 
    125         } 
    126         break; 
    127     case 'delete': 
    128         if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?')){ 
    129             return; 
    130         } 
    131         break; 
    132     case 'delete_order': 
    133         if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?\n\n※ 在庫数は手動で戻してください。')){ 
    134             return; 
    135         } 
     121    switch(mode) { 
     122    case 'delete_category': 
     123        if(!window.confirm('選択したカテゴリとカテゴリ内のすべてのカテゴリを削除します')){ 
     124            return; 
     125        } 
     126        break; 
     127    case 'delete': 
     128        if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?')){ 
     129            return; 
     130        } 
     131        break; 
     132    case 'delete_order': 
     133        if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?\n\n※ 在庫数は手動で戻してください。')){ 
     134            return; 
     135        } 
    136136        mode = 'delete'; 
    137         break; 
    138     case 'confirm': 
    139         if(!window.confirm('登録しても宜しいですか')){ 
    140             return; 
    141         } 
    142         break; 
    143     case 'delete_all': 
    144         if(!window.confirm('検索結果をすべて削除しても宜しいですか')){ 
    145             return; 
    146         } 
    147         break; 
    148     default: 
    149         break; 
    150     } 
    151     document.form1['mode'].value = mode; 
    152     if(keyname != "" && keyid != "") { 
    153         document.form1[keyname].value = keyid; 
    154     } 
    155     document.form1.submit(); 
     137        break; 
     138    case 'confirm': 
     139        if(!window.confirm('登録しても宜しいですか')){ 
     140            return; 
     141        } 
     142        break; 
     143    case 'delete_all': 
     144        if(!window.confirm('検索結果をすべて削除しても宜しいですか')){ 
     145            return; 
     146        } 
     147        break; 
     148    default: 
     149        break; 
     150    } 
     151    document.form1['mode'].value = mode; 
     152    if(keyname != "" && keyid != "") { 
     153        document.form1[keyname].value = keyid; 
     154    } 
     155    document.form1.submit(); 
    156156} 
    157157 
    158158function fnFormModeSubmit(form, mode, keyname, keyid) { 
    159     switch(mode) { 
    160     case 'delete': 
    161         if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?')){ 
    162             return; 
    163         } 
    164         break; 
    165     case 'confirm': 
    166         if(!window.confirm('登録しても宜しいですか')){ 
    167             return; 
    168         } 
    169         break; 
    170     case 'regist': 
    171         if(!window.confirm('登録しても宜しいですか')){ 
    172             return; 
    173         } 
    174         break; 
    175     default: 
    176         break; 
    177     } 
    178     document.forms[form]['mode'].value = mode; 
    179     if(keyname != "" && keyid != "") { 
    180         document.forms[form][keyname].value = keyid; 
    181     } 
    182     document.forms[form].submit(); 
     159    switch(mode) { 
     160    case 'delete': 
     161        if(!window.confirm('一度削除したデータは、元に戻せません。\n削除しても宜しいですか?')){ 
     162            return; 
     163        } 
     164        break; 
     165    case 'confirm': 
     166        if(!window.confirm('登録しても宜しいですか')){ 
     167            return; 
     168        } 
     169        break; 
     170    case 'regist': 
     171        if(!window.confirm('登録しても宜しいですか')){ 
     172            return; 
     173        } 
     174        break; 
     175    default: 
     176        break; 
     177    } 
     178    document.forms[form]['mode'].value = mode; 
     179    if(keyname != "" && keyid != "") { 
     180        document.forms[form][keyname].value = keyid; 
     181    } 
     182    document.forms[form].submit(); 
    183183} 
    184184 
    185185function fnSetFormSubmit(form, key, val) { 
    186     document.forms[form][key].value = val; 
    187     document.forms[form].submit(); 
    188     return false; 
     186    document.forms[form][key].value = val; 
     187    document.forms[form].submit(); 
     188    return false; 
    189189} 
    190190 
    191191function fnSetVal(key, val) { 
    192     fnSetFormVal('form1', key, val); 
     192    fnSetFormVal('form1', key, val); 
    193193} 
    194194 
    195195function fnSetFormVal(form, key, val) { 
    196     document.forms[form][key].value = val; 
     196    document.forms[form][key].value = val; 
    197197} 
    198198 
    199199function fnChangeAction(url) { 
    200     document.form1.action = url; 
     200    document.form1.action = url; 
    201201} 
    202202 
    203203// ページナビで使用する。 
    204204function fnNaviPage(pageno) { 
    205     document.form1['pageno'].value = pageno; 
    206     document.form1.submit(); 
     205    document.form1['pageno'].value = pageno; 
     206    document.form1.submit(); 
    207207} 
    208208 
    209209function fnSearchPageNavi(pageno) { 
    210     document.form1['pageno'].value = pageno; 
    211     document.form1['mode'].value = 'search'; 
    212     document.form1.submit(); 
    213     } 
     210    document.form1['pageno'].value = pageno; 
     211    document.form1['mode'].value = 'search'; 
     212    document.form1.submit(); 
     213    } 
    214214 
    215215function fnSubmit(){ 
    216     document.form1.submit(); 
     216    document.form1.submit(); 
    217217} 
    218218 
    219219// ポイント入力制限。 
    220220function fnCheckInputPoint() { 
    221     if(document.form1['point_check']) { 
    222         list = new Array( 
    223                         'use_point' 
    224                         ); 
    225  
    226         if(!document.form1['point_check'][0].checked) { 
    227             color = "#dddddd"; 
    228             flag = true; 
    229         } else { 
    230             color = ""; 
    231             flag = false; 
    232         } 
    233  
    234         len = list.length 
    235         for(i = 0; i < len; i++) { 
    236             if(document.form1[list[i]]) { 
    237                 document.form1[list[i]].disabled = flag; 
    238                 document.form1[list[i]].style.backgroundColor = color; 
    239             } 
    240         } 
    241     } 
     221    if(document.form1['point_check']) { 
     222        list = new Array( 
     223                        'use_point' 
     224                        ); 
     225 
     226        if(!document.form1['point_check'][0].checked) { 
     227            color = "#dddddd"; 
     228            flag = true; 
     229        } else { 
     230            color = ""; 
     231            flag = false; 
     232        } 
     233 
     234        len = list.length 
     235        for(i = 0; i < len; i++) { 
     236            if(document.form1[list[i]]) { 
     237                document.form1[list[i]].disabled = flag; 
     238                document.form1[list[i]].style.backgroundColor = color; 
     239            } 
     240        } 
     241    } 
    242242} 
    243243 
    244244// 別のお届け先入力制限。 
    245245function fnCheckInputDeliv() { 
    246     if(!document.form1) { 
    247         return; 
    248     } 
    249     if(document.form1['deliv_check']) { 
    250         list = new Array( 
    251                         'shipping_name01', 
    252                         'shipping_name02', 
    253                         'shipping_kana01', 
    254                         'shipping_kana02', 
    255                         'shipping_pref', 
    256                         'shipping_zip01', 
    257                         'shipping_zip02', 
    258                         'shipping_addr01', 
    259                         'shipping_addr02', 
    260                         'shipping_tel01', 
    261                         'shipping_tel02', 
    262                         'shipping_tel03' 
    263                         ); 
    264  
    265         if(!document.form1['deliv_check'].checked) { 
    266             fnChangeDisabled(list, '#dddddd'); 
    267         } else { 
    268             fnChangeDisabled(list, ''); 
    269         } 
    270     } 
     246    if(!document.form1) { 
     247        return; 
     248    } 
     249    if(document.form1['deliv_check']) { 
     250        list = new Array( 
     251                        'shipping_name01', 
     252                        'shipping_name02', 
     253                        'shipping_kana01', 
     254                        'shipping_kana02', 
     255                        'shipping_pref', 
     256                        'shipping_zip01', 
     257                        'shipping_zip02', 
     258                        'shipping_addr01', 
     259                        'shipping_addr02', 
     260                        'shipping_tel01', 
     261                        'shipping_tel02', 
     262                        'shipping_tel03' 
     263                        ); 
     264 
     265        if(!document.form1['deliv_check'].checked) { 
     266            fnChangeDisabled(list, '#dddddd'); 
     267        } else { 
     268            fnChangeDisabled(list, ''); 
     269        } 
     270    } 
    271271} 
    272272 
     
    275275 
    276276function fnChangeDisabled(list, color) { 
    277     len = list.length; 
    278  
    279     for(i = 0; i < len; i++) { 
    280         if(document.form1[list[i]]) { 
    281             if(color == "") { 
    282                 // 有効にする。 
    283                 document.form1[list[i]].disabled = false; 
    284                 document.form1[list[i]].style.backgroundColor = g_savecolor[list[i]]; 
    285             } else { 
    286                 // 無効にする。 
    287                 document.form1[list[i]].disabled = true; 
    288                 g_savecolor[list[i]] = document.form1[list[i]].style.backgroundColor; 
    289                 document.form1[list[i]].style.backgroundColor = color;//"#f0f0f0"; 
    290             } 
    291         } 
    292     } 
     277    len = list.length; 
     278 
     279    for(i = 0; i < len; i++) { 
     280        if(document.form1[list[i]]) { 
     281            if(color == "") { 
     282                // 有効にする。 
     283                document.form1[list[i]].disabled = false; 
     284                document.form1[list[i]].style.backgroundColor = g_savecolor[list[i]]; 
     285            } else { 
     286                // 無効にする。 
     287                document.form1[list[i]].disabled = true; 
     288                g_savecolor[list[i]] = document.form1[list[i]].style.backgroundColor; 
     289                document.form1[list[i]].style.backgroundColor = color;//"#f0f0f0"; 
     290            } 
     291        } 
     292    } 
    293293} 
    294294 
     
    296296// ログイン時の入力チェック 
    297297function fnCheckLogin(formname) { 
    298     var lstitem = new Array(); 
    299  
    300     if(formname == 'login_mypage'){ 
    301     lstitem[0] = 'mypage_login_email'; 
    302     lstitem[1] = 'mypage_login_pass'; 
    303     }else{ 
    304     lstitem[0] = 'login_email'; 
    305     lstitem[1] = 'login_pass'; 
    306     } 
    307     var max = lstitem.length; 
    308     var errflg = false; 
    309     var cnt = 0; 
    310  
    311     // 必須項目のチェック 
    312     for(cnt = 0; cnt < max; cnt++) { 
    313         if(document.forms[formname][lstitem[cnt]].value == "") { 
    314             errflg = true; 
    315             break; 
    316         } 
    317     } 
    318  
    319     // 必須項目が入力されていない場合 
    320     if(errflg == true) { 
    321         alert('メールアドレス/パスワードを入力して下さい。'); 
    322         return false; 
    323     } 
     298    var lstitem = new Array(); 
     299 
     300    if(formname == 'login_mypage'){ 
     301    lstitem[0] = 'mypage_login_email'; 
     302    lstitem[1] = 'mypage_login_pass'; 
     303    }else{ 
     304    lstitem[0] = 'login_email'; 
     305    lstitem[1] = 'login_pass'; 
     306    } 
     307    var max = lstitem.length; 
     308    var errflg = false; 
     309    var cnt = 0; 
     310 
     311    // 必須項目のチェック 
     312    for(cnt = 0; cnt < max; cnt++) { 
     313        if(document.forms[formname][lstitem[cnt]].value == "") { 
     314            errflg = true; 
     315            break; 
     316        } 
     317    } 
     318 
     319    // 必須項目が入力されていない場合 
     320    if(errflg == true) { 
     321        alert('メールアドレス/パスワードを入力して下さい。'); 
     322        return false; 
     323    } 
    324324} 
    325325 
    326326// 時間の計測. 
    327327function fnPassTime(){ 
    328     end_time = new Date(); 
    329     time = end_time.getTime() - start_time.getTime(); 
    330     alert((time/1000)); 
     328    end_time = new Date(); 
     329    time = end_time.getTime() - start_time.getTime(); 
     330    alert((time/1000)); 
    331331} 
    332332start_time = new Date(); 
     
    334334//親ウィンドウのページを変更する. 
    335335function fnUpdateParent(url) { 
    336     // 親ウィンドウの存在確認 
    337     if(fnIsopener()) { 
    338         window.opener.location.href = url; 
    339     } else { 
    340         window.close(); 
    341     } 
     336    // 親ウィンドウの存在確認 
     337    if(fnIsopener()) { 
     338        window.opener.location.href = url; 
     339    } else { 
     340        window.close(); 
     341    } 
    342342} 
    343343 
    344344//特定のキーをSUBMITする. 
    345345function fnKeySubmit(keyname, keyid) { 
    346     if(keyname != "" && keyid != "") { 
    347         document.form1[keyname].value = keyid; 
    348     } 
    349     document.form1.submit(); 
     346    if(keyname != "" && keyid != "") { 
     347        document.form1[keyname].value = keyid; 
     348    } 
     349    document.form1.submit(); 
    350350} 
    351351 
     
    355355//引数3:カウント結果格納対象 
    356356function fnCharCount(form,sch,cnt) { 
    357     document.forms[form][cnt].value= document.forms[form][sch].value.length; 
     357    document.forms[form][cnt].value= document.forms[form][sch].value.length; 
    358358} 
    359359 
  • branches/version-2_5-dev/html/js/win_op.js

    r20116 r20566  
    2020 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. 
    2121 */ 
    22 <!-- 
    23     function win01(URL,Winname,Wwidth,Wheight){ 
    24         var WIN; 
    25         WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=no,resizable=no,toolbar=no,location=no,directories=no,status=no"); 
    26         WIN.focus(); 
    27     } 
    28 // --> 
    29      
    30 <!-- 
    31     function win02(URL,Winname,Wwidth,Wheight){ 
    32         var WIN; 
    33         WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no"); 
    34         WIN.focus(); 
    35     } 
    36 // --> 
    3722 
    38 <!-- 
    39     function win03(URL,Winname,Wwidth,Wheight){ 
    40         var WIN; 
    41         WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no,menubar=no"); 
    42         WIN.focus(); 
    43     } 
    44 // --> 
     23function win01(URL,Winname,Wwidth,Wheight){ 
     24    var WIN; 
     25    WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=no,resizable=no,toolbar=no,location=no,directories=no,status=no"); 
     26    WIN.focus(); 
     27} 
    4528 
    46 <!-- 
     29function win02(URL,Winname,Wwidth,Wheight){ 
     30    var WIN; 
     31    WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no"); 
     32    WIN.focus(); 
     33} 
     34 
     35function win03(URL,Winname,Wwidth,Wheight){ 
     36    var WIN; 
     37    WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no,menubar=no"); 
     38    WIN.focus(); 
     39} 
     40 
    4741function winSubmit(URL,formName,Winname,Wwidth,Wheight){ 
    48     var WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no,menubar=no"); 
     42    var WIN = window.open(URL,Winname,"width="+Wwidth+",height="+Wheight+",scrollbars=yes,resizable=yes,toolbar=no,location=no,directories=no,status=no,menubar=no"); 
    4943    document.forms[formName].target = Winname; 
    5044    WIN.focus(); 
    5145} 
    52 //--> 
Note: See TracChangeset for help on using the changeset viewer.