Corveda / PHPSandbox

A PHP-based sandboxing library with a full suite of configuration and validation options.
https://phpsandbox.org
Other
220 stars 46 forks source link

Possibble to use PHP's DateTime class? #8

Closed jasondavis closed 7 years ago

jasondavis commented 7 years ago

Running this code $TwoWeeksAgo = new DateTime(date("Ymd"));

on the demno here https://code.phpsandbox.org/ results in this error message:

Sandboxed code attempted to call invalid type: DateTime

Is there a way to make this work?

jasondavis commented 7 years ago

Sorry seems I just needed to have different settings, etc