PHP Class think\response\Redirect

Inheritance: extends think\Response
Afficher le fichier Open project: top-think/framework Class Usage Examples

Protected Properties

Свойство Type Description
$options
$params URL参数

Méthodes publiques

Méthode Description
__construct ( $data = '', $code = 302, array $header = [], array $options = [] )
getTargetUrl ( ) : string 获取跳转地址
params ( $params = [] )
remember ( ) 记住当前url后跳转
restore ( ) 跳转到上次记住的url
with ( string | array $name, mixed $value = null ) 重定向传值(通过Session)

Méthodes protégées

Méthode Description
output ( mixed $data ) : mixed 处理数据

Method Details

__construct() public méthode

public __construct ( $data = '', $code = 302, array $header = [], array $options = [] )
$header array
$options array

getTargetUrl() public méthode

获取跳转地址
public getTargetUrl ( ) : string
Résultat string

output() protected méthode

处理数据
protected output ( mixed $data ) : mixed
$data mixed 要处理的数据
Résultat mixed

params() public méthode

public params ( $params = [] )

remember() public méthode

记住当前url后跳转
public remember ( )

restore() public méthode

跳转到上次记住的url
public restore ( )

with() public méthode

重定向传值(通过Session)
public with ( string | array $name, mixed $value = null )
$name string | array 变量名或者数组
$value mixed

Property Details

$options protected_oe property

protected $options

$params protected_oe property

URL参数
protected $params