2 /*************************************************************************************
5 * Author: Alan Juden (alan@judenware.org)
6 * Copyright: (c) 2004 Alan Juden, Nigel McNie (http://qbnz.com/highlighter/)
7 * Release Version: 1.0.8.3
8 * Date Started: 2004/07/10
10 * Smarty template language file for GeSHi.
20 *************************************************************************************
22 * This file is part of GeSHi.
24 * GeSHi is free software; you can redistribute it and/or modify
25 * it under the terms of the GNU General Public License as published by
26 * the Free Software Foundation; either version 2 of the License, or
27 * (at your option) any later version.
29 * GeSHi is distributed in the hope that it will be useful,
30 * but WITHOUT ANY WARRANTY; without even the implied warranty of
31 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32 * GNU General Public License for more details.
34 * You should have received a copy of the GNU General Public License
35 * along with GeSHi; if not, write to the Free Software
36 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
38 ************************************************************************************/
40 $language_data = array (
41 'LANG_NAME' => 'Smarty',
42 'COMMENT_SINGLE' => array(),
43 'COMMENT_MULTI' => array('{*' => '*}'),
44 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
45 'QUOTEMARKS' => array("'", '"'),
46 'ESCAPE_CHAR' => '\\',
49 '$smarty', 'now', 'const', 'capture', 'config', 'section', 'foreach', 'template', 'version', 'ldelim', 'rdelim',
50 'foreachelse', 'include', 'include_php', 'insert', 'if', 'elseif', 'else', 'php',
51 'sectionelse', 'is_cached',
54 'capitalize', 'count_characters', 'cat', 'count_paragraphs', 'count_sentences', 'count_words', 'date_format',
55 'default', 'escape', 'indent', 'lower', 'nl2br', 'regex_replace', 'replace', 'spacify', 'string_format',
56 'strip', 'strip_tags', 'truncate', 'upper', 'wordwrap',
59 'counter', 'cycle', 'debug', 'eval', 'html_checkboxes', 'html_image', 'html_options',
60 'html_radios', 'html_select_date', 'html_select_time', 'html_table', 'math', 'mailto', 'popup_init',
64 '$template_dir', '$compile_dir', '$config_dir', '$plugins_dir', '$debugging', '$debug_tpl',
65 '$debugging_ctrl', '$autoload_filters', '$compile_check', '$force_compile', '$caching', '$cache_dir',
66 '$cache_lifetime', '$cache_handler_func', '$cache_modified_check', '$config_overwrite',
67 '$config_booleanize', '$config_read_hidden', '$config_fix_newlines', '$default_template_handler_func',
68 '$php_handling', '$security', '$secure_dir', '$security_settings', '$trusted_dir', '$left_delimiter',
69 '$right_delimiter', '$compiler_class', '$request_vars_order', '$request_use_auto_globals',
70 '$error_reporting', '$compile_id', '$use_sub_dirs', '$default_modifiers', '$default_resource_type'
73 'append', 'append_by_ref', 'assign', 'assign_by_ref', 'clear_all_assign', 'clear_all_cache',
74 'clear_assign', 'clear_cache', 'clear_compiled_tpl', 'clear_config', 'config_load', 'display',
75 'fetch', 'get_config_vars', 'get_registered_object', 'get_template_vars',
76 'load_filter', 'register_block', 'register_compiler_function', 'register_function',
77 'register_modifier', 'register_object', 'register_outputfilter', 'register_postfilter',
78 'register_prefilter', 'register_resource', 'trigger_error', 'template_exists', 'unregister_block',
79 'unregister_compiler_function', 'unregister_function', 'unregister_modifier', 'unregister_object',
80 'unregister_outputfilter', 'unregister_postfilter', 'unregister_prefilter', 'unregister_resource'
83 'name', 'file', 'scope', 'global', 'key', 'once', 'script',
84 'loop', 'start', 'step', 'max', 'show', 'values', 'value', 'from', 'item'
87 'eq', 'neq', 'ne', 'lte', 'gte', 'ge', 'le', 'not', 'mod'
90 // some common php functions
91 'isset', 'is_array', 'empty', 'count', 'sizeof'
95 '/', '=', '==', '!=', '>', '<', '>=', '<=', '!', '%'
97 'CASE_SENSITIVE' => array(
98 GESHI_COMMENTS => false,
110 1 => 'color: #0600FF;', //Functions
111 2 => 'color: #008000;', //Modifiers
112 3 => 'color: #0600FF;', //Custom Functions
113 4 => 'color: #804040;', //Variables
114 5 => 'color: #008000;', //Methods
115 6 => 'color: #6A0A0A;', //Attributes
116 7 => 'color: #D36900;', //Text-based symbols
117 8 => 'color: #0600FF;' //php functions
120 'MULTI' => 'color: #008080; font-style: italic;'
122 'ESCAPE_CHAR' => array(
123 0 => 'color: #000099; font-weight: bold;'
126 0 => 'color: #D36900;'
129 0 => 'color: #ff0000;'
132 0 => 'color: #cc66cc;'
135 1 => 'color: #006600;'
138 0 => 'color: #D36900;'
142 1 => 'color: #808080; font-style: italic;',
143 2 => 'color: #009000;'
146 0 => 'color: #00aaff;'
150 1 => 'http://smarty.php.net/{FNAMEL}',
151 2 => 'http://smarty.php.net/{FNAMEL}',
152 3 => 'http://smarty.php.net/{FNAMEL}',
153 4 => 'http://smarty.php.net/{FNAMEL}',
154 5 => 'http://smarty.php.net/{FNAMEL}',
156 7 => 'http://smarty.php.net/{FNAMEL}',
160 'OBJECT_SPLITTERS' => array(
165 0 => '\$[a-zA-Z][a-zA-Z0-9_]*'
167 'STRICT_MODE_APPLIES' => GESHI_ALWAYS,
168 'SCRIPT_DELIMITERS' => array(
179 'HIGHLIGHT_STRICT_BLOCK' => array(
184 'PARSER_CONTROL' => array(
186 'DISALLOWED_BEFORE' => "(?<![a-zA-Z0-9\$_\|\#;>|^])",
187 'DISALLOWED_AFTER' => "(?![a-zA-Z0-9_<\|%\\-&])"