web\Controller renderAjax()

renderAjax() public method

Renders a view in response to an AJAX request.

This method is similar to renderPartial() except that it will inject into the rendering result with JS/CSS scripts and files which are registered with the view. For this reason, you should use this method instead of renderPartial() to render a view to respond to an AJAX request.

public string renderAjax ( $view, $params = [] )
$view string

The view name. Please refer to render() on how to specify a view name.

$params array

The parameters (name-value pairs) that should be made available in the view.

return string

The rendering result.

doc_Yii
2016-10-30 17:14:46
Comments
Leave a Comment

Please login to continue.