0
0
mirror of https://github.com/phpv8/v8js.git synced 2024-11-08 20:08:41 +00:00
phpv8/samples/test_date.php
2012-04-27 16:26:15 +00:00

10 lines
210 B
PHP

<?php
$a = new V8Js();
try {
var_dump($a->executeString("date = new Date('September 8, 1975 09:00:00'); print(date + '\\n'); date;", "test.js"));
} catch (V8JsException $e) {
echo $e->getMessage(), "\n";
}