jsFile() public static method
Generates a script tag that refers to an external JavaScript file.
See also yii\helpers\Url::to().
| public static string jsFile ( $url, $options = [] ) | ||
|---|---|---|
| $url | string |
The URL of the external JavaScript file. This parameter will be processed by yii\helpers\Url::to(). |
| $options | array |
The tag options in terms of name-value pairs. The following option is specially handled:
The rest of the options will be rendered as the attributes of the resulting script tag. The values will be HTML-encoded using encode(). If a value is null, the corresponding attribute will not be rendered. See renderTagAttributes() for details on how attributes are being rendered. |
| return | string |
The generated script tag |
Please login to continue.