src/Controller/AbstractController.php
protected function outputCssAndJs()
    {
        // We only do this once per output type.
        $result = isset(static::$jsCssSend[$this->destination]);
        static::$jsCssSend[$this->destination] = true;
        if ($result === true) {
            // Been here, done that.
            return '';
        }

        // Adding our DOM tools to the js.
        if ($this->pool->fileService->fileIsReadable(KREXX_DIR . 'resources/jsLibs/kdt.min.js') === true) {
            $kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.min.js';
        } else {
            $kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.js';
        }
        $jsCode = $this->pool->fileService->getFileContents($kdtPath);

        // Adding the skin css and js.
        $skinDirectory = $this->pool->config->getSkinDirectory();
        // Get the css file.
        $css = $this->pool->fileService->getFileContents($skinDirectory . 'skin.css');
        // Remove whitespace.
        $css = preg_replace('/\s+/', ' ', $css);
        // Krexx.js is comes directly form the template.
        if ($this->pool->fileService->fileIsReadable($skinDirectory . 'krexx.min.js') === true) {
            $skinJsPath = $skinDirectory . 'krexx.min.js';
        } else {
            $skinJsPath = $skinDirectory . 'krexx.js';
        }
        $jsCode .= $this->pool->fileService->getFileContents($skinJsPath);

        return $this->pool->render->renderCssJs($css, $jsCode);
    }
protected function outputCssAndJs()
    {
        // We only do this once per output type.
        $result = isset(static::$jsCssSend[$this->destination]);
        static::$jsCssSend[$this->destination] = true;
        if ($result === true) {
            // Been here, done that.
            return '';
        }

        // Adding our DOM tools to the js.
        if ($this->pool->fileService->fileIsReadable(KREXX_DIR . 'resources/jsLibs/kdt.min.js') === true) {
            $kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.min.js';
        } else {
            $kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.js';
        }
        $jsCode = $this->pool->fileService->getFileContents($kdtPath);

        // Adding the skin css and js.
        $skinDirectory = $this->pool->config->getSkinDirectory();
        // Get the css file.
        $css = $this->pool->fileService->getFileContents($skinDirectory . 'skin.css');
        // Remove whitespace.
        $css = preg_replace('/\s+/', ' ', $css);
        // Krexx.js is comes directly form the template.
        if ($this->pool->fileService->fileIsReadable($skinDirectory . 'krexx.min.js') === true) {
            $skinJsPath = $skinDirectory . 'krexx.min.js';
        } else {
            $skinJsPath = $skinDirectory . 'krexx.js';
        }
        $jsCode .= $this->pool->fileService->getFileContents($skinJsPath);

        return $this->pool->render->renderCssJs($css, $jsCode);
    }
protected function outputCssAndJs ( ) { // We only do this once per output type. $ result = isset ( static :: $ jsCssSend [ $ this -> destination ] ) ; static :: $ jsCssSend [ $ this -> destination ] = true ; if ( $ result === true ) { // Been here, done that. return '' ; } // Adding our DOM tools to the js. if ( $ this -> pool -> fileService -> fileIsReadable ( KREXX_DIR . 'resources/jsLibs/kdt.min.js' ) === true ) { $ kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.min.js' ; } else { $ kdtPath = KREXX_DIR . 'resources/jsLibs/kdt.js' ; } $ jsCode = $ this -> pool -> fileService -> getFileContents ( $ kdtPath ) ; // Adding the skin css and js. $ skinDirectory = $ this -> pool -> config -> getSkinDirectory ( ) ; // Get the css file. $ css = $ this -> pool -> fileService -> getFileContents ( $ skinDirectory . 'skin.css' ) ; // Remove whitespace. $ css = preg_replace ( '/\s+/' , ' ' , $ css ) ; // Krexx.js is comes directly form the template. if ( $ this -> pool -> fileService -> fileIsReadable ( $ skinDirectory . 'krexx.min.js' ) === true ) { $ skinJsPath = $ skinDirectory . 'krexx.min.js' ; } else { $ skinJsPath = $ skinDirectory . 'krexx.js' ; } $ jsCode .= $ this -> pool -> fileService -> getFileContents ( $ skinJsPath ) ; return $ this -> pool -> render -> renderCssJs ( $ css , $ jsCode ) ; }
Outputs the CSS and JS.

@return string
The generated markup.
Outputs the CSS and JS .