Skip to content

Commit

Permalink
view support multiple template engine
Browse files Browse the repository at this point in the history
  • Loading branch information
dcto committed Feb 16, 2023
1 parent c0c6cc5 commit 2414802
Show file tree
Hide file tree
Showing 54 changed files with 246 additions and 219 deletions.
13 changes: 9 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"ext-openssl": "*",
"ext-mbstring": "*",
"psr/log": "1.*",
"vlucas/phpdotenv":"3.3",
"guzzlehttp/guzzle":"7.*",
"illuminate/contracts": "7.*",
"illuminate/container": "7.*",
Expand All @@ -36,12 +37,16 @@
"illuminate/http":"7.*",
"illuminate/support": "7.*",
"illuminate/pagination": "7.*",
"vlucas/phpdotenv":"3.3"
"windwalker/renderer":"3.*"
},
"suggest": {
"hashids/hashids": "Required HashID In the Eloquent",
"nesbot/carbon": "Include Carbon DateTime Formating",
"twig/twig": "Required Twig 3.x Of View Module"
"hashids/hashids": "Suggest HashID In the Eloquent",
"nesbot/carbon": "Suggest Carbon DateTime Formating",
"twig/twig": "Suggest Twig 2.x Of View Engine",
"league/plates": "Suggest Plates 3.x Of View Engine",
"windwalker/edge": "Suggest Edge 3.x Of View Engine",
"illuminate/view": "Suggest Blade 7.* Of View Engine",
"mustache/mustache": "Suggest Mustcache 2.x Of View Engine"
},
"autoload": {
"psr-4": {
Expand Down
4 changes: 2 additions & 2 deletions src/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace VM;

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down Expand Up @@ -276,7 +276,7 @@ public function cli()
}

/**
* GET Varimax The Full Stack PHP Frameworks Version"
* GET Varimax The Slim PHP Frameworks Version"
* @return string
*/
public function version()
Expand Down
2 changes: 1 addition & 1 deletion src/Bootstrap.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Cache.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/ApcDriver.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/Driver.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax.cn
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/DriverInterface.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/FileSystemDriver.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/FilesDriver.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/NullDriver.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Cache/Driver/RedisDriver.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Config/Config.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
6 changes: 3 additions & 3 deletions src/Controller.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down Expand Up @@ -89,10 +89,9 @@ protected function make($abstract, array $parameters = [])
*/
protected function view($template, $variable = [])
{
return make('view')->show($template, $variable);
return make('view')->display($template, $variable);
}


/**
* [assign]
*
Expand All @@ -105,6 +104,7 @@ protected function assign($var, $val = null)
make('view')->assign($var, $val);
}


public function __destruct()
{
$this->off();
Expand Down
2 changes: 1 addition & 1 deletion src/Crypt/Crypt.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/E.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/FatalError.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/FileException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/HttpException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/LogicException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/NotFoundException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/ServiceException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/SystemException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/FileSystem/FileSystem.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Cookie.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Curl/Curl.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Curl/Response.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Redirect.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Request.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Request/Upload.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/Base.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/BinaryFile.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/Json.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/Redirect.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/Response.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/ResponseTrait.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Response/Streamed.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Session/Handler/FilesSessionHandler.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Session/Handler/MemcacheSessionHandler.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Session/Handler/MemcachedSessionHandler.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Session/Handler/NullSessionHandler.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Varimax The Full Stack PHP Frameworks.
* Varimax The Slim PHP Frameworks.
* varimax
* FILE: 2020
* USER: 陶之11. <[email protected]>
Expand Down
Loading

0 comments on commit 2414802

Please sign in to comment.