Seite 1 von 1

userInput type="date" year range?

Verfasst: Di 22. Jun 2010, 12:41
von Michael_S
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.

Re: userInput type="date" year range?

Verfasst: Di 22. Jun 2010, 13:37
von Liquid
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

Re: userInput type="date" year range?

Verfasst: Di 22. Jun 2010, 14:41
von Michael_S
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.