Daily Lucky Numbers:
1
7
15
44
46
48

Change from Weekly to Daily Date Stamp

Started by Fog, February 15, 2014, 10:48:04 PM

Previous topic - Next topic

Fog

I'm trying to modify this pickems game I found into a NCAA Bracket Game...

With football pickems it's a weekly date stamp or cut off.

function getCutoffDateTime($week) {
//get the cutoff date for a given week
global $db_prefix;
$sql = "select gameTimeEastern from " . $db_prefix . "schedule where weekNum = " . $week . " and DATE_FORMAT(gameTimeEastern, '%x') = '2014' order by gameTimeEastern limit 1; ";
$qryCutoff = mysql_query($sql);
if (mysql_num_rows($qryCutoff) > 0) {
$rstCutoff = mysql_fetch_array($qryCutoff);
return $rstCutoff['gameTimeEastern'];
}
die('Error getting cutoff date: ' . mysql_error());


I'm trying to convert weeks into days (rounds)

March Madness has several rounds within one week and I get a small error when I use the week table as a daily table and it shows up as a cutoff time.