This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Javascript and setting dates...

 
Kevin P Smith
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just wonder, is there an easy way to set a future date in Javascript using the Date object?

See I was looking at the Java Calendar object and you can do something simple like:



To set the date to the current date + 90 days.

Now I need to do something liek this in Javascript, but there is no Calendar object in Javascript , only the Date object and from what I can see you can not set a futire date in this way using Date().

Does anyone knwo hoe to do this?
 
Kevin P Smith
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorted it

Simple really:

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic