Changeset 1491 for trunk/template


Ignore:
Timestamp:
Jul 22, 2006, 11:21:40 AM (18 years ago)
Author:
chrisaga
Message:

fix bugs 244: different display of checkbox in IE/firefox and 484: Missing onfocus/onblur

in some user section *.tpl and many admin section *.tpl
handle FORM elements with a behaviour (inputfix.htc) in IE
the behaviour sets onfocus and onblur events too (no longer needed in *.tpl)
other browsers use css selector :focus and [type=_]

Location:
trunk/template/yoga
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • trunk/template/yoga/admin/configuration.tpl

    r1448 r1491  
    1818        <label for="gallery_title">{lang:Gallery title}</label>
    1919      </span>
    20       <input type="text" maxlength="255" size="50" name="gallery_title" id="gallery_title" value="{general.CONF_GALLERY_TITLE}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     20      <input type="text" maxlength="255" size="50" name="gallery_title" id="gallery_title" value="{general.CONF_GALLERY_TITLE}" />
    2121    </li>
    2222
     
    2525        <label for="page_banner">{lang:Page banner}</label>
    2626      </span>
    27       <textarea class="description" name="page_banner" id="page_banner" onfocus="this.className='description focus';" onblur="this.className='description nofocus';">{general.CONF_PAGE_BANNER}</textarea>
     27      <textarea class="description" name="page_banner" id="page_banner">{general.CONF_PAGE_BANNER}</textarea>
    2828    </li>
    2929
     
    3232        <label for="gallery_url">{lang:Gallery URL}</label>
    3333      </span>
    34       <input type="text" maxlength="255" size="50" name="gallery_url" id="gallery_url" value="{general.CONF_GALLERY_URL}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     34      <input type="text" maxlength="255" size="50" name="gallery_url" id="gallery_url" value="{general.CONF_GALLERY_URL}" />
    3535    </li>
    3636
     
    7777        <label for="nb_comment_page">{lang:Number of comments per page}</label>
    7878      </span>
    79       <input type="text" size="3" maxlength="4" name="nb_comment_page" id="nb_comment_page" value="{comments.NB_COMMENTS_PAGE}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     79      <input type="text" size="3" maxlength="4" name="nb_comment_page" id="nb_comment_page" value="{comments.NB_COMMENTS_PAGE}" />
    8080    </li>
    8181
     
    9797        <label for="default_language">{lang:Language}</label>
    9898      </span>
    99       <select name="default_language" id="default_language" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     99      <select name="default_language" id="default_language">
    100100        <!-- BEGIN language_option -->
    101101        <option value="{default.language_option.VALUE}" {default.language_option.SELECTED}>{default.language_option.CONTENT}</option>
     
    108108        <label for="nb_image_line">{lang:Number of images per row}</label>
    109109      </span>
    110       <input type="text" size="3" maxlength="2" id="nb_image_line" name="nb_image_line" value="{default.NB_IMAGE_LINE}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     110      <input type="text" size="3" maxlength="2" id="nb_image_line" name="nb_image_line" value="{default.NB_IMAGE_LINE}" />
    111111    </li>
    112112
     
    115115        <label for="nb_line_page">{lang:Number of rows per page}</label>
    116116      </span>
    117       <input type="text" size="3" maxlength="2" id="nb_line_page" name="nb_line_page" value="{default.NB_ROW_PAGE}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     117      <input type="text" size="3" maxlength="2" id="nb_line_page" name="nb_line_page" value="{default.NB_ROW_PAGE}" />
    118118    </li>
    119119
     
    122122        <label for="default_template">{lang:Interface theme}</label>
    123123      </span>
    124       <select name="default_template" id="default_template" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     124      <select name="default_template" id="default_template">
    125125        <!-- BEGIN template_option -->
    126126        <option value="{default.template_option.VALUE}" {default.template_option.SELECTED}>{default.template_option.CONTENT}</option>
     
    133133        <label for="recent_period">{lang:Recent period}</label>
    134134      </span>
    135       <input type="text" size="3" maxlength="2" name="recent_period" id="recent_period" value="{default.CONF_RECENT}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     135      <input type="text" size="3" maxlength="2" name="recent_period" id="recent_period" value="{default.CONF_RECENT}" />
    136136    </li>
    137137
     
    152152        <label for="default_maxwidth">{lang:Maximum width of the pictures}</label>
    153153      </span>
    154       <input type="text" size="4" maxlength="4" id="default_maxwidth" name="default_maxwidth" value="{default.MAXWIDTH}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     154      <input type="text" size="4" maxlength="4" id="default_maxwidth" name="default_maxwidth" value="{default.MAXWIDTH}" />
    155155    </li>
    156156
     
    159159        <label for="default_maxheight">{lang:Maximum height of the pictures}</label>
    160160      </span>
    161       <input type="text" size="4" maxlength="4" id="default_maxheight" name="default_maxheight" value="{default.MAXHEIGHT}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     161      <input type="text" size="4" maxlength="4" id="default_maxheight" name="default_maxheight" value="{default.MAXHEIGHT}" />
    162162    </li>
    163163  </ul>
  • trunk/template/yoga/admin/group_list.tpl

    r1129 r1491  
    99      <label for="groupname">{lang:Group name}</label>
    1010    </span>
    11     <input type="text" id="groupname" name="groupname" maxlength="50" size="20" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     11    <input type="text" id="groupname" name="groupname" maxlength="50" size="20" />
    1212
    1313    <p>
  • trunk/template/yoga/admin/thumbnail.tpl

    r1129 r1491  
    7979          <label for="width">{lang:maximum width}</label>
    8080        </span>
    81         <input type="text" id="width" name="width" value="{params.WIDTH_TN}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     81        <input type="text" id="width" name="width" value="{params.WIDTH_TN}" />
    8282      </li>
    8383
     
    8686          <label for="height">{lang:maximum height}</label>
    8787        </span>
    88         <input type="text" id="height" name="height" value="{params.HEIGHT_TN}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     88        <input type="text" id="height" name="height" value="{params.HEIGHT_TN}" />
    8989      </li>
    9090
  • trunk/template/yoga/default-colors.css

    r1418 r1491  
    2222
    2323/* Tables & forms */
    24 INPUT, SELECT, TEXTAREA {
    25         color:black;
     24
     25/* IE <= 6 is so bad with this that you can't merge with the following rule */
     26INPUT[type="text"], INPUT[type="password"], INPUT[type="button"],
     27INPUT[type="submit"], INPUT[type="reset"], INPUT[type="file"] {
     28  color:black;
     29  background-color: #d3d3d3;    /* lightgrey */
    2630}
    27 INPUT, SELECT, TEXTAREA, FORM .nofocus {
    28         background-color: #d3d3d3;      /* lightgrey */
     31
     32INPUT.text, INPUT.password, INPUT.button,
     33INPUT.submit, INPUT.reset, INPUT.file,
     34SELECT, TEXTAREA {
     35  color:black;
     36  background-color: #d3d3d3;    /* lightgrey */
    2937}
    30 FORM .focus {
     38/*INPUT.text.focus, INPUT.password.focus, INPUT.button.focus,
     39INPUT.submit.focus, INPUT.reset.focus, INPUT.file.focus,*/
     40INPUT:focus, SELECT:focus, TEXTAREA:focus, INPUT.focus, FORM .focus {
    3141  background-color: #f5f5f5;            /* whitesmoke */
    32 }
    33 INPUT[type="radio"] {   /* for Opera */
    34   border: none;
    35   background-color: transparent;
    3642}
    3743
  • trunk/template/yoga/fix-ie5-ie6.css

    r1479 r1491  
    1212}
    1313
    14 /* to get less hugly checkboxes at least in tagSelection */
    15 /* as well as several forms */
    16 FORM#update FIELDSET INPUT,
    17 UL.tagSelection LI INPUT,
    18 #content UL.thumbnails SPAN.wrap2 INPUT {
     14/* some theme set a border on INPUT  which is not pretty for those */
     15INPUT.radio, INPUT.checkbox {
    1916  border: none;
    20   background-color: transparent;
    2117}
    2218
  • trunk/template/yoga/header.tpl

    r1475 r1491  
    2828    /* only because we need \{pwg_root\} otherwise use fix-ie5-ie6.css */
    2929    BODY { behavior:url("{pwg_root}template-common/csshover.htc"); }
    30     A IMG, .button, .icon { behavior:url("{pwg_root}template-common/tooltipfix.htc"); }
     30    A IMG, .button, .icon {
     31      behavior:url("{pwg_root}template-common/tooltipfix.htc");
     32    }
     33    FORM { behavior: url("{pwg_root}template-common/inputfix.htc"); }
    3134  </style>
    3235  <script type="text/javascript" src="{pwg_root}include/pngfix.js"></script>
  • trunk/template/yoga/identification.tpl

    r1143 r1491  
    3232          <label for="username">{L_USERNAME}</label>
    3333        </span>
    34         <input tabindex="1" class="login" type="text" name="username" id="username" size="25" maxlength="40" value="{USERNAME}" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     34        <input tabindex="1" class="login" type="text" name="username" id="username" size="25" maxlength="40" value="{USERNAME}" />
    3535      </li>
    3636
     
    3939          <label for="password">{L_PASSWORD}</label>
    4040        </span>
    41         <input tabindex="2" class="login" type="password" name="password" id="password" size="25" maxlength="25" onfocus="this.className='focus';" onblur="this.className='nofocus';" />
     41        <input tabindex="2" class="login" type="password" name="password" id="password" size="25" maxlength="25" />
    4242      </li>
    4343
  • trunk/template/yoga/menubar.tpl

    r1466 r1491  
    9090        <label>
    9191          {lang:Username}
    92           <input type="text" name="username" size="15" value="" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     92          <input type="text" name="username" size="15" value="">
    9393        </label>
    9494
    9595        <label>
    9696          {lang:password}
    97           <input type="password" name="password" size="15" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     97          <input type="password" name="password" size="15">
    9898        </label>
    9999
  • trunk/template/yoga/password.tpl

    r1129 r1491  
    3838          <label for="mail_address">{lang:Email address}</label>
    3939        </span>
    40         <input class="login" type="text" name="mail_address" id="mail_address" size="40" maxlength="40" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     40        <input class="login" type="text" name="mail_address" id="mail_address" size="40" maxlength="40" >
    4141      </li>
    42 
    4342      <li>
    4443        <span class="property">
  • trunk/template/yoga/profile.tpl

    r1244 r1491  
    2828        {USERNAME}
    2929      </li>
    30 
    3130      <li>
    3231        <span class="property">
    3332          <label for="mail_address">{lang:Email address}</label>
    3433        </span>
    35         <input type="text" name="mail_address" id="mail_address" value="{EMAIL}" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     34        <input type="text" name="mail_address" id="mail_address" value="{EMAIL}">
    3635      </li>
    37 
    3836      <li>
    3937        <span class="property">
    4038          <label for="password">{L_CURRENT_PASSWORD}</label>
    4139        </span>
    42         <input type="password" name="password" id="password" value="" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     40        <input type="password" name="password" id="password" value="">
    4341      </li>
    44 
    4542      <li>
    4643        <span class="property">
    4744          <label for="use_new_pwd">{L_NEW_PASSWORD}</label>
    4845        </span>
    49         <input type="password" name="use_new_pwd" id="use_new_pwd" value="" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     46        <input type="password" name="use_new_pwd" id="use_new_pwd" value="">
    5047      </li>
    51 
    5248      <li>
    5349        <span class="property">
    5450          <label for="passwordConf">{L_CONFIRM_PASSWORD}</label>
    5551        </span>
    56         <input type="password" name="passwordConf" id="passwordConf" value="" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     52        <input type="password" name="passwordConf" id="passwordConf" value="">
    5753      </li>
    5854    </ul>
     
    6763          <label for="nb_image_line">{L_NB_IMAGE_LINE}</label>
    6864        </span>
    69         <input type="text" size="3" maxlength="2" name="nb_image_line" id="nb_image_line" value="{NB_IMAGE_LINE}"
    70                onfocus="this.className='focus';" onblur="this.className='nofocus';">
     65        <input type="text" size="3" maxlength="2" name="nb_image_line" id="nb_image_line" value="{NB_IMAGE_LINE}">
    7166      </li>
    72 
    7367      <li>
    7468        <span class="property">
    7569          <label for="nb_line_page">{L_NB_ROW_PAGE}</label>
    7670        </span>
    77         <input type="text" size="3" maxlength="2" name="nb_line_page" id="nb_line_page" value="{NB_ROW_PAGE}"
    78                onfocus="this.className='focus';" onblur="this.className='nofocus';">
     71        <input type="text" size="3" maxlength="2" name="nb_line_page" id="nb_line_page" value="{NB_ROW_PAGE}" >
    7972      </li>
    80 
    8173      <li>
    8274        <span class="property">
    8375          <label for="template">{L_STYLE_SELECT}</label>
    8476        </span>
    85         <select name="template" id="template" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     77        <select name="template" id="template">
    8678          <!-- BEGIN template_option -->
    8779          <option value="{template_option.VALUE}" {template_option.SELECTED}>{template_option.CONTENT}</option>
     
    8981        </select>
    9082      </li>
    91 
    9283      <li>
    9384        <span class="property">
    9485          <label for="language">{L_LANG_SELECT}</label>
    9586        </span>
    96         <select name="language" id="language" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     87        <select name="language" id="language">
    9788          <!-- BEGIN language_option -->
    9889          <option value="{language_option.VALUE}" {language_option.SELECTED}>{language_option.CONTENT}</option>
     
    10091        </select>
    10192      </li>
    102 
    10393      <li>
    10494        <span class="property">
    10595          <label for="recent_period">{L_RECENT_PERIOD}</label>
    10696        </span>
    107         <input type="text" size="3" maxlength="2" name="recent_period" id="recent_period" value="{RECENT_PERIOD}"
    108                onfocus="this.className='focus';" onblur="this.className='nofocus';">
     97        <input type="text" size="3" maxlength="2" name="recent_period" id="recent_period" value="{RECENT_PERIOD}">
    10998      </li>
    110 
    11199      <li>
    112100        <span class="property">{L_EXPAND_TREE}</span>
    113         <label><input type="radio" class="radio" name="expand" value="true" {EXPAND_TREE_YES}> {L_YES}</label>
    114         <label><input type="radio" class="radio" name="expand" value="false" {EXPAND_TREE_NO}> {L_NO}</label>
     101        <label><input type="radio" name="expand" value="true" {EXPAND_TREE_YES}> {L_YES}</label>
     102        <label><input type="radio" name="expand" value="false" {EXPAND_TREE_NO}> {L_NO}</label>
    115103      </li>
    116 
    117104      <li>
    118105        <span class="property">{L_NB_COMMENTS}</span>
    119         <label><input type="radio" class="radio" name="show_nb_comments" value="true" {NB_COMMENTS_YES}> {L_YES}</label>
    120         <label><input type="radio" class="radio" name="show_nb_comments" value="false" {NB_COMMENTS_NO}> {L_NO}</label>
     106        <label><input type="radio" name="show_nb_comments" value="true" {NB_COMMENTS_YES}> {L_YES}</label>
     107        <label><input type="radio" name="show_nb_comments" value="false" {NB_COMMENTS_NO}> {L_NO}</label>
    121108      </li>
    122  
    123109      <li>
    124110        <span class="property">
    125111          <label for="maxwidth">{L_MAXWIDTH}</label>
    126112        </span>
    127         <input type="text" size="4" maxlength="4" name="maxwidth" id="maxwidth" value="{MAXWIDTH}"
    128                onfocus="this.className='focus';" onblur="this.className='nofocus';">
     113        <input type="text" size="4" maxlength="4" name="maxwidth" id="maxwidth" value="{MAXWIDTH}">
    129114      </li>
    130 
    131115      <li>
    132116        <span class="property">
    133117          <label for="maxheight">{L_MAXHEIGHT}</label>
    134118        </span>
    135         <input type="text" size="4" maxlength="4" name="maxheight" id="maxheight" value="{MAXHEIGHT}"
    136                onfocus="this.className='focus';" onblur="this.className='nofocus';">
     119        <input type="text" size="4" maxlength="4" name="maxheight" id="maxheight" value="{MAXHEIGHT}">
    137120      </li>
    138121    </ul>
     
    141124  <p class="bottomButtons">
    142125    <input type="submit" name="validate" value="{L_SUBMIT}">
    143     <input type="reset" name="reset" value="{L_RESET}">
     126    <input type="reset" name="reset" value="{L_RESET}" class="reset">
    144127  </p>
    145128
  • trunk/template/yoga/register.tpl

    r1143 r1491  
    2929          <label for="login">* {lang:Username}</label>
    3030        </span>
    31         <input type="text" name="login" id="login" value="{F_LOGIN}" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     31        <input type="text" name="login" id="login" value="{F_LOGIN}" >
    3232      </li>
    33 
    3433      <li>
    3534        <span class="property">
    3635          <label for="password">* {lang:Password}</label>
    3736        </span>
    38         <input type="password" name="password" id="password" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     37        <input type="password" name="password" id="password" >
    3938      </li>
    40 
    4139      <li>
    4240        <span class="property">
    4341          <label for="password_conf">* {lang:Confirm Password}</label>
    4442        </span>
    45         <input type="password" name="password_conf" id="password_conf" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     43        <input type="password" name="password_conf" id="password_conf" >
    4644      </li>
    47 
    4845      <li>
    4946        <span class="property">
    5047          <label for="mail_address">{lang:Mail address}</label>
    5148        </span>
    52         <input type="text" name="mail_address" id="mail_address" value="{F_EMAIL}" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     49        <input type="text" name="mail_address" id="mail_address" value="{F_EMAIL}" >
    5350        ({lang:useful when password forgotten})
    5451      </li>
  • trunk/template/yoga/search.tpl

    r1446 r1491  
    2323  <legend>{lang:Filter}</legend>
    2424  <label>{lang:search_keywords}
    25     <input type="text" style="width: 300px" name="search_allwords" size="30"  onfocus="this.className='focus';" onblur="this.className='nofocus';"/>
     25    <input type="text" style="width: 300px" name="search_allwords" size="30"  />
    2626  </label>
    2727  <ul>
     
    3434  </ul>
    3535  <label>{lang:search_author}
    36     <input type="text" style="width: 300px" name="search_author" size="30"  onfocus="this.className='focus';" onblur="this.className='nofocus';"/>
     36    <input type="text" style="width: 300px" name="search_author" size="30"  />
    3737  </label>
    3838</fieldset>
     
    7171        <!-- END start_month -->
    7272      </select>
    73       <input name="start_year" type="text" size="4" maxlength="4" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     73      <input name="start_year" type="text" size="4" maxlength="4" >
    7474    </li>
    7575    <li>
     
    9090        <!-- END end_month -->
    9191      </select>
    92       <input name="end_year" type="text" size="4" maxlength="4" onfocus="this.className='focus';" onblur="this.className='nofocus';">
     92      <input name="end_year" type="text" size="4" maxlength="4" >
    9393    </li>
    9494    <li>
     
    101101  <legend>{lang:search_options}</legend>
    102102  <label>{lang:search_categories}
    103     <select class="categoryList" name="cat[]" multiple="multiple" onfocus="this.className='categoryList focus';" onblur="this.className='categoryList nofocus';">
     103    <select class="categoryList" name="cat[]" multiple="multiple" >
    104104      <!-- BEGIN category_option -->
    105105      <option value="{category_option.VALUE}">{category_option.OPTION}</option>
Note: See TracChangeset for help on using the changeset viewer.