I was leaning toward that it was a version restriction. I tried your solution and it worked but the day before I stumbled across $firstDate = date_create_from_format('Y/m/d', '2013-08-27'); $secondDate = date_create_from_format('Y/m/d', '2013-09-02'); And this one worked also (despite). The pro games are 1-week behind the college games and their week begins on a Thursday. Post season begins vastly different for both. I'm thinking that calls for two separate procedures of nested if-than's (curProWk and curColWk) rather than some real complicated if then with a curWk.
Quite awhile ago I got your MySQL Client-Server Applications with Visual FoxPro and it was over my head. Should I try again or stick with Mysql Workbench? Again, thanks you guys Gary Jeurink -----Original Message----- From: Ted Roche [mailto:tedro...@gmail.com] Sent: Friday, October 25, 2013 6:08 PM To: profox@leafe.com Subject: Re: mysql workbench On Fri, Oct 25, 2013 at 6:49 PM, Gary Jeurink <g.jeur...@charter.net> wrote: > Thanks for your reply but the > False = 0 / N / .F. > True = 1 / Y / .T. > .. is over my head is that associate array? > > My biggest block today is how to set the value of a date variable without a > syntax error in PHP > > function getCurWeek() { > $curDate = Date('Y/m/d'); > $firstDate = DateTime::createFromFormat('Y/m/d', '2013-08-27'); > $secondDate = DateTime::createFromFormat('Y/m/d', '2013-09-02'); > if ($curDate >= $firstDate && $curDate <= $secondDate) > { > $curWeek = '01'; > return $curWeek; > } > First and second date won't fly > > Gary Jeurink > You are so close! createFromFormat says to use the format string you specify: 'Y/m/d' to parse the string '2013-08-27' - the Y, m and d are special character placeholders that specify 4-digit-year, month and day. The slashes are 'literal characters' that says there are slashes in the string to ignore. So, change the dashes in your string to slashes. Or change the slashes in your format string to dashes. -- Ted Roche Ted Roche & Associates, LLC http://www.tedroche.com --- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html --- _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/B420F162F4014BFA8E486A885DFA6886@OwnerPC ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.