PHP与RESTful

WBOY
Release: 2016-06-20 12:40:46
Original
881 people have browsed it

PHP与RESTful

2016.01.07 17:10:46

这一段时间在忙PHP App事宜,采用RESTful架构。

写个Demo程序:

<?phpheader('Content-Type: text/html; charset=utf-8');require 'Slim/Slim.php';\Slim\Slim::registerAutoloader();$app = new \Slim\Slim();$app->get('/:name', function ($name) {    echo "Hello, $name";});$app->run();
Copy after login

运行结果如下图所示:

接下来,就是各种逻辑封装、API构造、NoSQL使用、前端折腾、应用开发等等诸般任务项堆砌了,呵呵,有得忙有得折腾咯~

回头3、5年前的技术,放到今天来看,已显老套,技术更新迭代之快,超乎想像。在新技术模式下,PHP以往常被诟病的代码与标记混杂的缺点,其实已不太重要。因为,也许、可能根本不需要混杂了......

嘿嗨~,马上又是世界杯了......

收摊,吃西瓜去了!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!