userInput type="date" year range?

basic functions and we:tags
Michael_S
Senior Member
Beiträge: 160
Registriert: Mi 4. Feb 2004, 02:39
Wohnort: London / UK
Kontaktdaten:

userInput type="date" year range?

Beitragvon Michael_S » Di 22. Jun 2010, 12:41

Hi,

When using the userInput type="date" tag the year range is 1970 to 2018.

Is there a way to set the start year and range?

Michael.
Production Area
London, UK
http://productionarea.com

Liquid
Senior Member
Beiträge: 1172
Registriert: Do 8. Jan 2004, 12:31
Wohnort: Karlsruhe

Re: userInput type="date" year range?

Beitragvon Liquid » Di 22. Jun 2010, 13:37

Hi Michael,

I dont think that there is a way with we:tags but you can use "normal" input tag.
When you look at the source of the (Frontend)page you can see the naming Webedition uses for the inputs.
Should see something like

Code: Alles auswählen

<select size="1" name="we_ui_we_global_form[we_date_your_field_name_day]" id="we_ui_we_global_form[we_date_your_field_name_day]">
<option>01</option>
...
<option>31</option>
</select>
When you keep the naming of these inputs you can fill them with your values.
But you have to be more careful with changes e.g. when the form name changes you have to change the "we_ui_we_global_form" part manually.

The problem that the year range ends 2018 is imho a Unix Timestamp issue, I have no idea how webedition will react on dates beyond this date.

Best regards
Liquid
Gruß Liquid

Michael_S
Senior Member
Beiträge: 160
Registriert: Mi 4. Feb 2004, 02:39
Wohnort: London / UK
Kontaktdaten:

Re: userInput type="date" year range?

Beitragvon Michael_S » Di 22. Jun 2010, 14:41

Hi Liquid,

Thanks for the reply, I thought I would have to do it manually but it was worth asking. I guess the best way would be to use PHP to build the option list dynamically, that way I would have a tidy list.

Michael.
Production Area
London, UK
http://productionarea.com


Zurück zu „Creating templates“

Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 4 Gäste