Helpers\Request

The Helpers\Request class is used for detecting the type of request and retrieving the request.

getMethod()

Request::getMethod()

Returns either GET or POST, depending if a $_GET request or a $_POST request has happened.

getIpAddress()

Request::getIpAddress()

Returns the client's IP Address.

post()

Request::post($key)

Returns the post key.

get()

Request::get($key)

Returns the get key.

server()

Request::server($key)

Returns the server key.

headers()

Request::headers($key)

Returns the HTTP Request Headers key.

files()

Request::files($key)

Returns the file key.

put()

Request::put($key)

Returns the put key.

isAjax()

Request::isAjax()

Detect if the request is a ajax request.

isPost()

Request::isPost()

Detect if the request is a post request.

isGet()

Request::isGet()

Detect if the request is a get request.

isHead()

Request::isHead()

Detect if the request is a head request.

isPut()

Request::isPut()

Detect if the request is a put request.

isDelete()

Request::isDelete()

Detect if the request is a delete request.

isOptions()

Request::isOptions()

Detect if the request is an options request.

Helpers\Request的更多相关文章

  1. 快速搭建react项目骨架(按需加载、redux、axios、项目级目录等等)

    一.前言 最近整理了一下项目骨架,顺便自定义了一个脚手架,方便日后使用.我会从头开始,步骤一步步写明白,如果还有不清楚的可以评论区留言.先大致介绍一下这个骨架,我们采用 create-react-ap ...

  2. elasticsearch.helpers.ScanError: Scroll request has only succeeded on xx shards

    # 当index=''为空时出现此错误

  3. Helpers\SimpleCurl

    Helpers\SimpleCurl The SimpleCurl class is there to curl data from RESTful services. A lot of compan ...

  4. Helpers\RainCaptcha

    Helpers\RainCaptcha This class can validate CAPTCHA images with RainCaptcha. It can generate an URL ...

  5. Helpers\CSRF

    Helpers\CSRF CSRF Protection The CSRF helper is used to protect post request from cross site request ...

  6. pytest 12 函数传参和fixture传参数request

    前沿: 有的case,需要依赖于某些特定的case才可以执行,比如,登陆获取到的cookie,每次都需要带着他,为了确保是同一个用户,必须带着和登陆获取到的同一个cookies. 大部分的用例都会先登 ...

  7. Go 语言相关的优秀框架,库及软件列表

    If you see a package or project here that is no longer maintained or is not a good fit, please submi ...

  8. YII2中的Html助手和Request组件

    Html助手 1 .在@app\views\test的index.php中: <?php //引入命名空间 use yii\helpers\Html; ?> <?php //[一]表 ...

  9. Yii2 配置request组件解析 json数据

    在基础版本的config目录下 web.php 或者高级版config目录下的main.php中配置 'components' =>[ 'request' => [ 'parsers' = ...

随机推荐

  1. 《Genesis-3D开源游戏引擎完整实例教程-2D射击游戏篇03:子弹发射》

    3.子弹发射 子弹发射概述: 在打飞机游戏中,子弹是自动发射的.子弹与子弹之间间隔一定的时间,玩家通过上下左右控制游戏角色,来达到躲避敌人及击中敌人的操作. 发射原理: 抽象理解为有两个容器存放子弹, ...

  2. 转】Maven学习总结(六)——Maven与Eclipse整合

    原博文出自于: http://www.cnblogs.com/xdp-gacl/p/4052025.html 感谢! 一.安装Maven插件 下载下来的maven插件如下图所示:,插件存放的路径是:E ...

  3. Homework-10 the Enhanced Version

    经过一周对于JavaScript HTML语言等相关知识的学习,我终于基本完成了作业的要求,也是实现了我原先计划的第二部,推出了加强版的Homework-10 他由3个HTML组成,JS脚本直接选择嵌 ...

  4. Linux下文件的权限

    一.Linux下查看文件属性 命令为: [root@localhost ~]# ls -al 结果: ls是『list』的意思,重点在显示文件的文件名与相关属性.而选项『-al』则表示列出所有的文件详 ...

  5. Socket连接与HTTP连接

    我们在传输数据时,可以只使用(传输层)TCP/IP协议,但是那样的话,如果没有应用层,便无法识别数据内容,如果想要使传输的数据有意义,则必须使用到应用层协议,应用层协议有很多,比如HTTP.FTP.T ...

  6. c# 使用ChartDirector绘图的一些个人体会

    c# 使用ChartDirector绘图的一些个人体会 引言:       最近给客户做一个B/S架构的证券交易大屏幕软件,其中用到对证券指数的走势以及成交量的图形绘制,由于客户要求图形的清晰而且要做 ...

  7. OC内存管理基础

    OC 内存管理基础 一. retain和release基本使用 使用注意: 1.你想使用(占用)某个对象,就应该让对象的计数器+1(让对象做一次retain操作) 2.你不想再使用(占用)某个对象,就 ...

  8. 使用 Tomcat 7 新的连接池 —— Tomcat jdbc pool

    Tomcat 在 7.0 以前的版本都是使用 commons-dbcp 做为连接池的实现,但是 dbcp 饱受诟病,原因有: dbcp 是单线程的,为了保证线程安全会锁整个连接池 dbcp 性能不佳 ...

  9. 【转】python的内存管理机制

    http://developer.51cto.com/art/201007/213585.htm 内存管理,对于Python这样的动态语言,是至关重要的一部分,它在很大程度上甚至决定了Python的执 ...

  10. 2015南阳CCPC H - Sudoku 暴力

    H - Sudoku Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 无 Description Yi Sima was one of the best cou ...