diff --git a/examples/demo-first-steps/MyClass.php b/examples/demo-first-steps/MyClass.php index 958dea2..5e59bc4 100644 --- a/examples/demo-first-steps/MyClass.php +++ b/examples/demo-first-steps/MyClass.php @@ -1,30 +1,26 @@ . /** * Example class used to construct objects from a query */ -class MyClass { +class MyClass extends QUeried { function __construct() { - // If the property 'miao' is in this object, it's a string - if($this->miao) { - // But I prefere a DateTime object - $this->miao = DateTime::createFromFormat('Y-m-d H:i:s', $this->miao); - } - + // I prefere a datetime object, not a string retrieved from MySQL + $this->datetimes( 'miao' ); } } diff --git a/examples/demo-first-steps/load.php b/examples/demo-first-steps/load.php index 965fbca..8381cbf 100644 --- a/examples/demo-first-steps/load.php +++ b/examples/demo-first-steps/load.php @@ -1,29 +1,29 @@