jeeva Posted February 2, 2007 Share Posted February 2, 2007 hi frnds, How to get the last date by using php? Quote Link to comment Share on other sites More sharing options...
The Little Guy Posted February 2, 2007 Share Posted February 2, 2007 last date of what? The month, year, week? Please explain more Quote Link to comment Share on other sites More sharing options...
jeeva Posted February 2, 2007 Author Share Posted February 2, 2007 if current date is 02-02-2007 then it has to return 01-02-2007 Quote Link to comment Share on other sites More sharing options...
chronister Posted February 2, 2007 Share Posted February 2, 2007 $new_stamp=mktime(0,0,0,date(m)-1, date(d), date(y)); echo date("m-d-Y",$new_stamp); prints out 01-02-2007 Quote Link to comment Share on other sites More sharing options...
jeeva Posted February 2, 2007 Author Share Posted February 2, 2007 thanks guys......... Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.