Returns a object type Date result of convert the date passed as argument of the time zone specified in the attribute 'from', to the time zone specified
in the attribute 'to'. In case of missing one of the attributes, those of the user are assumed. The necessary corrections are made in case of having summer or winter schedule
in the different time zones.
1 date.timezone.convert
<date.timezone.convert
to='to'
from='from'
>
<time /> !
</date.timezone.convert>
Attributes | |||||
---|---|---|---|---|---|
Name | Type | Required | Default | Description | |
Ato | String | Time zone destination. It is the time zone to which the returned date will refer. In case of not having, the user's time zone will be taken. | |||
Afrom | String | Time zone origin. It is the time zone of the entry date as argument. In case of not having, the user's time zone will be taken. |
Arguments | |||||
---|---|---|---|---|---|
Name | Type | Required | Unique | Nullable | Description |
Etime | Date |
Returns | |
---|---|
Type | Description |
Date | Corresponding date for the time zone 'to' in the entry date in the time zone 'from'. |
Example
Example in which it is consulted the date in Madrid when in L.A (EEUU) are 23:34:30 of the day 11-05-2014.
Copy
<xsql-script name='date_timezone_convert_sample1'> <body> <println><date.timezone.convert to="Europa/Madrid" from="America/Los_Angeles"><date format='dd-MM-yyyyhh:mm:ss'>11-05-201423:34:30</date></date.timezone.convert ></println> </body> </xsql-script>