Prado\Web\Javascripts\TJavaScript::renderScriptBlocksCallback PHP 메소드

renderScriptBlocksCallback() 공개 정적인 메소드

Renders a list of javascript code
public static renderScriptBlocksCallback ( $scripts ) : string
리턴 string rendering result
    public static function renderScriptBlocksCallback($scripts)
    {
        if (count($scripts)) {
            return implode("\n", $scripts) . "\n";
        } else {
            return '';
        }
    }

Usage Example

예제 #1
0
 /**
  * @param THtmlWriter writer for the rendering purpose
  */
 public function renderEndScriptsCallback($writer)
 {
     $writer->write(TJavaScript::renderScriptBlocksCallback($this->_endScripts));
 }