袖珍型 PHP5 框架 Slim Framework
這是一個簡單的 PHP5 框架用來創建 RESTful 的 Web 應用,示例代碼:
<?php require 'Slim/Slim.php'; $app = new Slim(); $app->get('/hello/:name', function ($name) { echo "Hello, $name!"; }); $app->run(); ?>
特性列表
- HTTP routing
- Named routes
- Route passing
- Route redirects
- Route halting
- Middleware & Hooks
- Custom views
- HTTP caching
- Signed cookies
- Custom 404 page
- Custom 500 page
- Error handling
- Logging
系統要求
- Web server (URL rewrite module recommended)
- PHP >= 5.1
- libmcrypt > 2.4.x (if using encrypted cookies)
本文由用戶 fmms 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!