protected function getScriptJs(array $tag_frag, $test_for_js = true)
    {
        if (empty($tag_frag['script_js'])) {
            return ''; // Not possible; no JavaScript code.
        }
        if ($test_for_js && !$this->isScriptTagFragJs($tag_frag)) {
            return ''; // This script tag does not contain JavaScript.
        }
        return trim($tag_frag['script_js']); // JavaScript code.
    }