千尸一律,女星与偷腥男友阳台半裸激吻,王天逸行侠记
app\index\controller\index.php
<?php namespace app\index\controller; use think\request; class index { public function index(request $request) { # 获取浏览器输入框的值 dump($request->domain()); dump($request->pathinfo()); dump($request->path()); # 请求类型 dump($request->method()); dump($request->isget()); dump($request->ispost()); dump($request->isajax()); # 请求的参数 dump($request->get()); dump($request->param()); dump($request->post()); //session('name', 'onestopweb'); //cookie('email', 'onestopweb@163.com'); //session(null); //cookie('email',null); dump($request->session()); dump($request->cookie()); dump($request->param('type')); dump($request->cookie('email')); # 获取模块 控制器 操作 dump($request->module()); dump($request->controller()); dump($request->action()); # 获取url dump($request->url()); dump($request->baseurl()); } }
地址栏输入的链接:http://192.168.0.180:55/index/index/?name=chaoyi&type=blog
`string(23)` `"[http://192.168.0.180:55](http://192.168.0.180:55/)"` `string(22)` `"index/index/"` `string(17)` `"index/index/index"` `string(3)` `"get"` `bool(true)` `bool(false)` `bool(false)` `array``(2) {` `[``"name"``] => string(6)` `"chaoyi"` `[``"type"``] => string(4)` `"blog"` `}` `array``(2) {` `[``"name"``] => string(6)` `"chaoyi"` `[``"type"``] => string(4)` `"blog"` `}` `array``(0) {` `}` `array``(1) {` `[``"name"``] => string(10)` `"onestopweb"` `}` `array``(3) {` `[``"username"``] => string(6)` `"chaoyi"` `[``"phpsessid"``] => string(26)` `"nugcsr2j9krr2lhk8bntggl412"` `[``"email"``] => string(18)` `"onestopweb@163.com"` `}` `string(4)` `"blog"` `string(18)` `"onestopweb@163.com"` `string(5)` `"index"` `string(5)` `"index"` `string(5)` `"index"` `string(45)` `"/index/index/?name=chaoyi&type=blog"` `string(23)` `"/index/index/"`
原文链接:
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复
YII2框架中使用RBAC对模块,控制器,方法的权限控制及规则的使用示例
YII2框架中ActiveDataProvider与GridView的配合使用操作示例
PhpStorm的使用教程(本地运行PHP+远程开发+快捷键)
网友评论