From 2658600afe8f3e8eba00cc392d25dc0ce112b767 Mon Sep 17 00:00:00 2001 From: Geoff Doty Date: Fri, 23 Jun 2023 12:12:50 -0500 Subject: [PATCH] update docs/examples --- README.md | 5 +++-- examples/53oop.php | 8 ++++---- examples/extend.php | 8 ++++---- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 051b8dd..b65469f 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ There are **better options** out there now ### Requirements -- PHP 5.3+ +- PHP 5.4+ ([], php -S) ## Usage @@ -38,6 +38,8 @@ Create an `index.php` file and put the following code in it ```php + TRUE, 'index' => __FILE__)); +$app = new Mite(['debug' => TRUE, 'index' => __FILE__]); -$app->route('/', function() use($app) { - $app->view('views/index.tpl.php'); +$app->route('/53oop.php', function() use($app) { + $app->view('index.tpl.php'); }); $app->run(); \ No newline at end of file diff --git a/examples/extend.php b/examples/extend.php index 24ff84f..d48e2fe 100644 --- a/examples/extend.php +++ b/examples/extend.php @@ -1,4 +1,4 @@ -view('views\index.tpl.php'); + $this->view('index.tpl.php'); } } -$app = new test(array('debug' => TRUE, 'index' => __FILE__)); -$app->route('/', 'index'); +$app = new test(['debug' => TRUE, 'index' => __FILE__]); +$app->route('/extend.php', 'index'); $app->run(); \ No newline at end of file