request->isGet" to determine whether it is submitted in get mode. If it is submitted in get mode, 1 will be returned."/> request->isGet" to determine whether it is submitted in get mode. If it is submitted in get mode, 1 will be returned.">

Home >PHP Framework >YII >yii determines whether to submit in get mode

yii determines whether to submit in get mode

尚
Original
2019-12-09 13:44:352386browse

yii determines whether to submit in get mode

Yii2 provides several functions to determine the submission method, in the Yii::$app component.

(Recommended learning: yii framework)

Yii::$app->request->isPost

is used to judge post submission, if it returns 1

Yii::$app->request->isGet

is used to judge get submission, if If it is, return 1

Yii:$app->request->isAjax

for judging ajax submission, if it is, return 1

The above is the detailed content of yii determines whether to submit in get mode. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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