Skip to content

Instantly share code, notes, and snippets.

@codescribblr
Created February 13, 2014 21:41
Show Gist options
  • Select an option

  • Save codescribblr/8984464 to your computer and use it in GitHub Desktop.

Select an option

Save codescribblr/8984464 to your computer and use it in GitHub Desktop.
Timestamp Selectbox 15 min intervals
<?php
for ($i = 0; $i <= 1440; $i+=15) :
$date = date("g:i A",mktime(0,$i,0,1,1,2000));
?>
<select>
<option value="<?php echo $date; ?>"><?php echo $date; ?></option>
</select>
<?php
endfor;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment