Ignore:
Timestamp:
Oct 7, 2008, 9:18:55 PM (16 years ago)
Author:
rub
Message:

jQuery Datepicker:

o use id for selector
o check radio button on change date

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/template/goto/picture_modify.tpl

    r2674 r2680  
    66{literal}
    77<script type="text/javascript">
    8   pwg_initialization_datepicker("select[name=date_creation_day]", "select[name=date_creation_month]", "input[name=date_creation_year]", "input[name=date_creation_linked_date]");
     8  pwg_initialization_datepicker("#date_creation_day", "#date_creation_month", "#date_creation_year", "#date_creation_linked_date", "#date_creation_action_set");
    99</script>
    1010{/literal}
     
    9797          <label><input type="radio" name="date_creation_action" value="unset" /> {'unset'|@translate}</label>
    9898          <input type="radio" name="date_creation_action" value="set" id="date_creation_action_set" /> {'set to'|@translate}
    99           <select onmousedown="document.getElementById('date_creation_action_set').checked = true;" name="date_creation_day">
     99          <select id="date_creation_day" name="date_creation_day">
    100100            <option value="0">--</option>
    101101            {section name=day start=1 loop=32}
     
    103103            {/section}
    104104          </select>
    105           <select onmousedown="document.getElementById('date_creation_action_set').checked = true;" name="date_creation_month">
     105          <select id="date_creation_month" name="date_creation_month">
    106106            {html_options options=$month_list selected=$DATE_CREATION_MONTH_VALUE}
    107107          </select>
    108           <input onmousedown="document.getElementById('date_creation_action_set').checked = true;"
     108          <input id="date_creation_year"
    109109                 name="date_creation_year"
    110110                 type="text"
     
    112112                 maxlength="4"
    113113                 value="{$DATE_CREATION_YEAR_VALUE}" />
    114           <input name="date_creation_linked_date" type="hidden" size="10" disabled="disabled"/>
     114          <input id="date_creation_linked_date" name="date_creation_linked_date" type="hidden" size="10" disabled="disabled"/>
    115115        </td>
    116116      </tr>
Note: See TracChangeset for help on using the changeset viewer.