Skip to content

Instantly share code, notes, and snippets.

@tobz
Created September 10, 2013 21:04
Show Gist options
  • Save tobz/6515662 to your computer and use it in GitHub Desktop.
Save tobz/6515662 to your computer and use it in GitHub Desktop.
$job = array("frequency" => "weekly");
$frequency = $job["frequency"];
$interval = (
$frequency === "weekly"
? "INTERVAL 7 DAY"
: ($frequency === "monthly"
? "INTERVAL 1 MONTH"
: "INTERVAL 1 DAY"));
echo $interval;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment