public function script($script) {
        $md5 = md5($script);
        if (in_array($md5, self::$cssScriptHistory))
            return '';
        self::$cssScriptHistory[] = $md5;
        return "<script type=\"text/javascript\">\n/*<![CDATA[*/\n{$script}\n/*]]>*/\n</script>";
    }
public function script($script) {
        $md5 = md5($script);
        if (in_array($md5, self::$cssScriptHistory))
            return '';
        self::$cssScriptHistory[] = $md5;
        return "<script type=\"text/javascript\">\n/*<![CDATA[*/\n{$script}\n/*]]>*/\n</script>";
    }
public function script ( $ script ) { $ md5 = md5 ( $ script ) ; if ( in_array ( $ md5 , self :: $ cssScriptHistory ) ) return '' ; self :: $ cssScriptHistory [ ] = $ md5 ; return "<script type=\"text/javascript\">\n/*<![CDATA[*/\n{$script}\n/*]]>*/\n</script>" ; }
Register inline script. You can choose to insert a script only once and then if the same script is detected then it won't be inserted again.
@param mixed $script
@return string
Register inline script . You can choose to insert a script only once and then if the same script is detected then it won t be inserted again .