Welcome to the nuBuilder forums!

Please register and login to view forums and other content only available to registered users.

NuFormat

Post Reply
CoCiX
Posts: 6
Joined: Sun Mar 11, 2012 10:59 pm

NuFormat

Unread post by CoCiX »

Hey, i have this JavaScript and I want to return me a date to the textfield but instead of date it returns me a number like this 1332047810918
how i can use nuFormat to change it to a date?
can you give me an example?
thx a lot
var today = new Date();
var prwto = today.setDate(today.getDate()+3);
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: NuFormat

Unread post by admin »

nuFormat formats a date that starts off in this format 2012-03-21

The number you are getting is seconds since 1970.

You need to format it with JavaScript http://stackoverflow.com/questions/1056 ... javascript

Steven
Post Reply