Jamz Posted February 25, 2011 Share Posted February 25, 2011 Hi Guys, Been a while since I've been on here, but I'm currently bashing my head against a wall trying to figure this one out. Basically I have a calendar that outputs Monday through Sunday, and the user clicks on a date and outputs it to the URL.... ie. ?day=$day&month=$month&year=$year. Now the next part I need to find out what day (0-6) say the 25th Feb 2011 will be wday 5... now how can I do this in code? And before anyone says why not output it to url, I cannot as the first week and last weeks use different code Cheers James Quote Link to comment Share on other sites More sharing options...
MatthewJ Posted February 25, 2011 Share Posted February 25, 2011 date('w', mktime(0,0,0,$month,$day,$year)); Quote Link to comment Share on other sites More sharing options...
Jamz Posted February 25, 2011 Author Share Posted February 25, 2011 You are a legend! Spot on, didnt think it would be so easy. Quote Link to comment Share on other sites More sharing options...
MatthewJ Posted February 25, 2011 Share Posted February 25, 2011 Glad I could help 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.