Skip to content

Instantly share code, notes, and snippets.

@stefanooldeman
Created January 13, 2012 10:50
Show Gist options
  • Save stefanooldeman/1605508 to your computer and use it in GitHub Desktop.
Save stefanooldeman/1605508 to your computer and use it in GitHub Desktop.
wip trying to check on negative timestamp support and how to detect it
<?php
//if this php version is greater than 5.1 pass
echo strtotime('1766-06-04') . '<br />';
if (version_compare(PHP_VERSION, '5.1', '>')) {
echo 'we support negative dates';
} else {
echo 'we DON'T support negative dates';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment