Forum: Rails deployment How to change date format from Y/m/d to Y-m-d

Posted by Annie smith (anniesmith)
on 2011-07-19 15:49
Hi all,

How to change date format from Y/m/d to Y-m-d in ruby?
thanks
Posted by esha d. (esha_d)
on 2011-07-29 07:26
Date.today.strftime('%Y-%m-%d')

Esha
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.