on 03-22-2012 8:42 AM
Hi All
I have to develop an webpage where I have to show the time select with timezone information from Server. How to get the timezone of server on the webpage.
Many thanks in advance.
Cheers
Rupesh
You can get the timezone of the MII server in a Transaction using something like this in the link editor
datefromxmlformat( datenow, "zzzz" ) and assign this value to an output parameter.
You can then get the value to your page via ajax or if you are using an irpt page you can use an xacute query and a servlet tag.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thansk Cristian, I had simillar thing in my mind to do but rather than taking timezone from MII server, I think I will get the from the database and write a Query template for it.
I was wondering if there is any ready way to do that, like some service under ..XMII/Illuminator?Service=SystemInfo through which We can get that info.
@Rajesh : The Javascript runs on Client machine and I am pretty sure that function will return date on the Client Machine and not on Server.
Thanks
Hi Rupesh,
You can get Server timezone information on webpage using JS.
create a function in JS and call the function in webpage
function startDate()
{
//Calculation for Start Date
var date = new Date();
var theyear = date.getFullYear();
var themonth = date.getMonth()+1;
var thetoday = date.getDate();
var StartDate = themonth+"/"+thetoday+"/"+theyear;
}
Hope this helps!!!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
11 | |
6 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.