From fb760d249e5c4e86c1255829fe6a0e15a4beb5e1 Mon Sep 17 00:00:00 2001 From: messerbill Date: Mon, 19 Aug 2013 16:49:59 +0200 Subject: [PATCH] added wysiwyg --- .../wysiwyg/distribution/demo.php | 35 + .../wysiwyg/distribution/readme.txt | 38 + .../distribution/wysiwyg/css/popup.css | 16 + .../distribution/wysiwyg/css/wysiwyg.css | 65 + .../wysiwyg/images/popup/exit.gif | Bin 0 -> 60 bytes .../wysiwyg/images/smileys/alien.gif | Bin 0 -> 1021 bytes .../wysiwyg/images/smileys/angry.gif | Bin 0 -> 465 bytes .../wysiwyg/images/smileys/arrowleft.gif | Bin 0 -> 1120 bytes .../wysiwyg/images/smileys/arrowright.gif | Bin 0 -> 1117 bytes .../wysiwyg/images/smileys/blink.gif | Bin 0 -> 1088 bytes .../wysiwyg/images/smileys/blush.gif | Bin 0 -> 482 bytes .../wysiwyg/images/smileys/blush2.gif | Bin 0 -> 1152 bytes .../wysiwyg/images/smileys/cap.gif | Bin 0 -> 704 bytes .../wysiwyg/images/smileys/closedeyes.gif | Bin 0 -> 472 bytes .../wysiwyg/images/smileys/clover.gif | Bin 0 -> 1156 bytes .../wysiwyg/images/smileys/confused.gif | Bin 0 -> 492 bytes .../wysiwyg/images/smileys/cool.gif | Bin 0 -> 696 bytes .../wysiwyg/images/smileys/crazy.gif | Bin 0 -> 1025 bytes .../wysiwyg/images/smileys/cry.gif | Bin 0 -> 696 bytes .../wysiwyg/images/smileys/cylon.gif | Bin 0 -> 1695 bytes .../wysiwyg/images/smileys/dontgetit.gif | Bin 0 -> 695 bytes .../wysiwyg/images/smileys/evil.gif | Bin 0 -> 1112 bytes .../wysiwyg/images/smileys/evilmad.gif | Bin 0 -> 695 bytes .../wysiwyg/images/smileys/evo.gif | Bin 0 -> 700 bytes .../wysiwyg/images/smileys/excl.gif | Bin 0 -> 1131 bytes .../wysiwyg/images/smileys/fear.gif | Bin 0 -> 652 bytes .../wysiwyg/images/smileys/fun.gif | Bin 0 -> 1014 bytes .../wysiwyg/images/smileys/geek.gif | Bin 0 -> 676 bytes .../wysiwyg/images/smileys/greedy.gif | Bin 0 -> 449 bytes .../wysiwyg/images/smileys/grin.gif | Bin 0 -> 697 bytes .../wysiwyg/images/smileys/grin2.gif | Bin 0 -> 676 bytes .../wysiwyg/images/smileys/happy.gif | Bin 0 -> 699 bytes .../wysiwyg/images/smileys/hehe.gif | Bin 0 -> 449 bytes .../wysiwyg/images/smileys/hmm.gif | Bin 0 -> 699 bytes .../wysiwyg/images/smileys/huh.gif | Bin 0 -> 708 bytes .../wysiwyg/images/smileys/idea.gif | Bin 0 -> 1046 bytes .../wysiwyg/images/smileys/kiss.gif | Bin 0 -> 5004 bytes .../wysiwyg/images/smileys/laugh.gif | Bin 0 -> 815 bytes .../wysiwyg/images/smileys/lol.gif | Bin 0 -> 1066 bytes .../wysiwyg/images/smileys/love.gif | Bin 0 -> 1069 bytes .../wysiwyg/images/smileys/ninja.gif | Bin 0 -> 481 bytes .../wysiwyg/images/smileys/no.gif | Bin 0 -> 1614 bytes .../wysiwyg/images/smileys/noexpression.gif | Bin 0 -> 1137 bytes .../wysiwyg/images/smileys/nugget.gif | Bin 0 -> 697 bytes .../wysiwyg/images/smileys/nuke.gif | Bin 0 -> 1127 bytes .../wysiwyg/images/smileys/ohmy.gif | Bin 0 -> 1099 bytes .../wysiwyg/images/smileys/pirate.gif | Bin 0 -> 1124 bytes .../wysiwyg/images/smileys/question.gif | Bin 0 -> 1107 bytes .../wysiwyg/images/smileys/ras.gif | Bin 0 -> 1301 bytes .../wysiwyg/images/smileys/rolleyes.gif | Bin 0 -> 705 bytes .../wysiwyg/images/smileys/sad.gif | Bin 0 -> 1099 bytes .../wysiwyg/images/smileys/sad2.gif | Bin 0 -> 689 bytes .../wysiwyg/images/smileys/shifty.gif | Bin 0 -> 901 bytes .../wysiwyg/images/smileys/shutup.gif | Bin 0 -> 19930 bytes .../wysiwyg/images/smileys/sick.gif | Bin 0 -> 703 bytes .../wysiwyg/images/smileys/sleepy.gif | Bin 0 -> 1121 bytes .../wysiwyg/images/smileys/sly.gif | Bin 0 -> 500 bytes .../wysiwyg/images/smileys/smart.gif | Bin 0 -> 1051 bytes .../wysiwyg/images/smileys/smile.gif | Bin 0 -> 1125 bytes .../wysiwyg/images/smileys/smile2.gif | Bin 0 -> 699 bytes .../wysiwyg/images/smileys/sneaky.gif | Bin 0 -> 492 bytes .../wysiwyg/images/smileys/songwhistle.gif | Bin 0 -> 1140 bytes .../wysiwyg/images/smileys/spidey.gif | Bin 0 -> 672 bytes .../wysiwyg/images/smileys/tongue.gif | Bin 0 -> 698 bytes .../wysiwyg/images/smileys/tongue2.gif | Bin 0 -> 1099 bytes .../wysiwyg/images/smileys/unsure.gif | Bin 0 -> 699 bytes .../wysiwyg/images/smileys/unsure2.gif | Bin 0 -> 1018 bytes .../wysiwyg/images/smileys/w00t.gif | Bin 0 -> 1058 bytes .../wysiwyg/images/smileys/wacko.gif | Bin 0 -> 946 bytes .../wysiwyg/images/smileys/wink.gif | Bin 0 -> 699 bytes .../wysiwyg/images/smileys/yawn.gif | Bin 0 -> 296 bytes .../wysiwyg/images/smileys/yes.gif | Bin 0 -> 1307 bytes .../wysiwyg/images/smileys/yucky.gif | Bin 0 -> 2063 bytes .../wysiwyg/images/wysiwyg/bold.gif | Bin 0 -> 76 bytes .../wysiwyg/images/wysiwyg/bold_on.gif | Bin 0 -> 76 bytes .../wysiwyg/images/wysiwyg/colorback.gif | Bin 0 -> 138 bytes .../wysiwyg/images/wysiwyg/colorback_on.gif | Bin 0 -> 185 bytes .../wysiwyg/images/wysiwyg/colorfore.gif | Bin 0 -> 114 bytes .../wysiwyg/images/wysiwyg/colorfore_on.gif | Bin 0 -> 174 bytes .../wysiwyg/images/wysiwyg/colors.png | Bin 0 -> 1286 bytes .../wysiwyg/images/wysiwyg/hyperlink.gif | Bin 0 -> 304 bytes .../wysiwyg/images/wysiwyg/hyperlink_on.gif | Bin 0 -> 309 bytes .../wysiwyg/images/wysiwyg/indent.gif | Bin 0 -> 90 bytes .../wysiwyg/images/wysiwyg/indent_on.gif | Bin 0 -> 90 bytes .../wysiwyg/images/wysiwyg/info.gif | Bin 0 -> 651 bytes .../wysiwyg/images/wysiwyg/info_on.gif | Bin 0 -> 651 bytes .../images/wysiwyg/inserthorizontalrule.gif | Bin 0 -> 1007 bytes .../wysiwyg/inserthorizontalrule_on.gif | Bin 0 -> 1018 bytes .../images/wysiwyg/insertorderedlist.gif | Bin 0 -> 84 bytes .../images/wysiwyg/insertorderedlist_on.gif | Bin 0 -> 84 bytes .../images/wysiwyg/insertunorderedlist.gif | Bin 0 -> 83 bytes .../images/wysiwyg/insertunorderedlist_on.gif | Bin 0 -> 83 bytes .../wysiwyg/images/wysiwyg/italic.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/italic_on.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/justifycenter.gif | Bin 0 -> 79 bytes .../images/wysiwyg/justifycenter_on.gif | Bin 0 -> 70 bytes .../wysiwyg/images/wysiwyg/justifyfull.gif | Bin 0 -> 80 bytes .../wysiwyg/images/wysiwyg/justifyfull_on.gif | Bin 0 -> 71 bytes .../wysiwyg/images/wysiwyg/justifyleft.gif | Bin 0 -> 80 bytes .../wysiwyg/images/wysiwyg/justifyleft_on.gif | Bin 0 -> 71 bytes .../wysiwyg/images/wysiwyg/justifyright.gif | Bin 0 -> 79 bytes .../images/wysiwyg/justifyright_on.gif | Bin 0 -> 70 bytes .../wysiwyg/images/wysiwyg/outdent.gif | Bin 0 -> 90 bytes .../wysiwyg/images/wysiwyg/outdent_on.gif | Bin 0 -> 90 bytes .../wysiwyg/images/wysiwyg/picture.gif | Bin 0 -> 622 bytes .../wysiwyg/images/wysiwyg/picture_on.gif | Bin 0 -> 625 bytes .../wysiwyg/images/wysiwyg/redo.gif | Bin 0 -> 336 bytes .../wysiwyg/images/wysiwyg/redo_on.gif | Bin 0 -> 339 bytes .../wysiwyg/images/wysiwyg/smileys.gif | Bin 0 -> 1106 bytes .../wysiwyg/images/wysiwyg/smileys_on.gif | Bin 0 -> 1106 bytes .../wysiwyg/images/wysiwyg/strikethrough.gif | Bin 0 -> 91 bytes .../images/wysiwyg/strikethrough_on.gif | Bin 0 -> 80 bytes .../wysiwyg/images/wysiwyg/subscript.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/subscript_on.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/superscript.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/superscript_on.gif | Bin 0 -> 79 bytes .../wysiwyg/images/wysiwyg/table.gif | Bin 0 -> 1022 bytes .../wysiwyg/images/wysiwyg/table_on.gif | Bin 0 -> 1018 bytes .../wysiwyg/images/wysiwyg/underline.gif | Bin 0 -> 87 bytes .../wysiwyg/images/wysiwyg/underline_on.gif | Bin 0 -> 87 bytes .../wysiwyg/images/wysiwyg/undo.gif | Bin 0 -> 333 bytes .../wysiwyg/images/wysiwyg/undo_on.gif | Bin 0 -> 334 bytes .../wysiwyg/distribution/wysiwyg/js/popup.js | 160 ++ .../wysiwyg/distribution/wysiwyg/js/utils.js | 72 + .../distribution/wysiwyg/js/wysiwyg.js | 185 ++ .../distribution/wysiwyg/php/.htaccess | 3 + .../wysiwyg/distribution/wysiwyg/php/api.php | 29 + .../wysiwyg/distribution/wysiwyg/php/data.php | 87 + .../wysiwyg/distribution/wysiwyg/php/init.php | 10 + .../distribution/wysiwyg/smarty/.htaccess | 3 + .../wysiwyg/smarty/Config_File.class.php | 393 +++ .../wysiwyg/smarty/Smarty.class.php | 1961 ++++++++++++++ .../wysiwyg/smarty/Smarty_Compiler.class.php | 2365 +++++++++++++++++ .../distribution/wysiwyg/smarty/debug.tpl | 157 ++ .../core.assemble_plugin_filepath.php | 67 + .../core.assign_smarty_interface.php | 43 + .../internals/core.create_dir_structure.php | 79 + .../internals/core.display_debug_console.php | 61 + .../internals/core.get_include_path.php | 44 + .../smarty/internals/core.get_microtime.php | 23 + .../internals/core.get_php_resource.php | 80 + .../smarty/internals/core.is_secure.php | 59 + .../smarty/internals/core.is_trusted.php | 47 + .../smarty/internals/core.load_plugins.php | 125 + .../internals/core.load_resource_plugin.php | 74 + .../internals/core.process_cached_inserts.php | 71 + .../core.process_compiled_include.php | 37 + .../smarty/internals/core.read_cache_file.php | 101 + .../wysiwyg/smarty/internals/core.rm_auto.php | 71 + .../wysiwyg/smarty/internals/core.rmdir.php | 54 + .../internals/core.run_insert_handler.php | 71 + .../internals/core.smarty_include_php.php | 50 + .../internals/core.write_cache_file.php | 96 + .../internals/core.write_compiled_include.php | 91 + .../core.write_compiled_resource.php | 35 + .../smarty/internals/core.write_file.php | 61 + .../smarty/plugins/block.textformat.php | 103 + .../smarty/plugins/compiler.assign.php | 40 + .../plugins/function.assign_debug_info.php | 40 + .../smarty/plugins/function.config_load.php | 142 + .../smarty/plugins/function.counter.php | 80 + .../wysiwyg/smarty/plugins/function.cycle.php | 102 + .../wysiwyg/smarty/plugins/function.debug.php | 35 + .../wysiwyg/smarty/plugins/function.eval.php | 49 + .../wysiwyg/smarty/plugins/function.fetch.php | 221 ++ .../plugins/function.html_checkboxes.php | 143 + .../smarty/plugins/function.html_image.php | 142 + .../smarty/plugins/function.html_options.php | 122 + .../smarty/plugins/function.html_radios.php | 156 ++ .../plugins/function.html_select_date.php | 331 +++ .../plugins/function.html_select_time.php | 194 ++ .../smarty/plugins/function.html_table.php | 177 ++ .../smarty/plugins/function.mailto.php | 165 ++ .../wysiwyg/smarty/plugins/function.math.php | 85 + .../wysiwyg/smarty/plugins/function.popup.php | 119 + .../smarty/plugins/function.popup_init.php | 40 + .../smarty/plugins/modifier.capitalize.php | 43 + .../wysiwyg/smarty/plugins/modifier.cat.php | 33 + .../plugins/modifier.count_characters.php | 32 + .../plugins/modifier.count_paragraphs.php | 29 + .../plugins/modifier.count_sentences.php | 29 + .../smarty/plugins/modifier.count_words.php | 33 + .../smarty/plugins/modifier.date_format.php | 58 + .../plugins/modifier.debug_print_var.php | 90 + .../smarty/plugins/modifier.default.php | 32 + .../smarty/plugins/modifier.escape.php | 93 + .../smarty/plugins/modifier.indent.php | 28 + .../wysiwyg/smarty/plugins/modifier.lower.php | 26 + .../wysiwyg/smarty/plugins/modifier.nl2br.php | 35 + .../smarty/plugins/modifier.regex_replace.php | 48 + .../smarty/plugins/modifier.replace.php | 30 + .../smarty/plugins/modifier.spacify.php | 30 + .../smarty/plugins/modifier.string_format.php | 29 + .../wysiwyg/smarty/plugins/modifier.strip.php | 33 + .../smarty/plugins/modifier.strip_tags.php | 32 + .../smarty/plugins/modifier.truncate.php | 50 + .../wysiwyg/smarty/plugins/modifier.upper.php | 26 + .../smarty/plugins/modifier.wordwrap.php | 29 + .../plugins/outputfilter.trimwhitespace.php | 75 + .../plugins/shared.escape_special_chars.php | 31 + .../smarty/plugins/shared.make_timestamp.php | 46 + .../distribution/wysiwyg/temp/.htaccess | 3 + .../distribution/wysiwyg/temp/cache/.blank | 0 .../distribution/wysiwyg/temp/compile/.blank | 0 .../distribution/wysiwyg/templates/.htaccess | 3 + .../wysiwyg/templates/popup/popup.html | 5 + .../templates/popup/popup_centered.html | 5 + .../wysiwyg/templates/wysiwyg/blank.html | 3 + .../wysiwyg/templates/wysiwyg/command.html | 11 + .../wysiwyg/templates/wysiwyg/popup.html | 11 + .../templates/wysiwyg/popup_colorback.html | 11 + .../templates/wysiwyg/popup_colorfore.html | 11 + .../templates/wysiwyg/popup_hyperlink.html | 4 + .../wysiwyg/templates/wysiwyg/popup_info.html | 5 + .../templates/wysiwyg/popup_picture.html | 5 + .../templates/wysiwyg/popup_smileys.html | 13 + .../templates/wysiwyg/popup_table.html | 4 + .../wysiwyg/templates/wysiwyg/select.html | 1 + .../wysiwyg/templates/wysiwyg/wysiwyg.html | 66 + 219 files changed, 10686 insertions(+) create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/demo.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/readme.txt create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/popup.css create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/wysiwyg.css create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/popup/exit.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/alien.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/angry.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/arrowleft.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/arrowright.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/blink.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/blush.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/blush2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cap.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/closedeyes.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/clover.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/confused.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cool.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/crazy.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cry.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cylon.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/dontgetit.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evil.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evilmad.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evo.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/excl.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/fear.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/fun.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/geek.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/greedy.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/grin.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/grin2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/happy.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hehe.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hmm.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/huh.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/idea.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/kiss.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/laugh.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/lol.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/love.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ninja.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/no.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/noexpression.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/nugget.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/nuke.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ohmy.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/pirate.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/question.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ras.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/rolleyes.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sad.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sad2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shifty.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shutup.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sick.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sleepy.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sly.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/smart.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/smile.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/smile2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sneaky.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/songwhistle.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/spidey.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/unsure.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/unsure2.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/w00t.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/wacko.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/wink.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yawn.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yes.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yucky.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/bold.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/bold_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorback.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorback_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colors.png create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/hyperlink.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/hyperlink_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/indent.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/indent_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/inserthorizontalrule.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/inserthorizontalrule_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertunorderedlist.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertunorderedlist_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/redo.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/redo_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/smileys.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/smileys_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/strikethrough.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/strikethrough_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/subscript.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/subscript_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/superscript.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/superscript_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/table.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/table_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/underline.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/underline_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo_on.gif create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/js/popup.js create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/js/utils.js create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/js/wysiwyg.js create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/.htaccess create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/api.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/data.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/init.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/.htaccess create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Config_File.class.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty.class.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty_Compiler.class.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/debug.tpl create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assemble_plugin_filepath.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assign_smarty_interface.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.create_dir_structure.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.display_debug_console.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_include_path.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_microtime.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_php_resource.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_secure.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_trusted.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_plugins.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_resource_plugin.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_cached_inserts.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_compiled_include.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.read_cache_file.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rm_auto.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rmdir.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.run_insert_handler.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.smarty_include_php.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_cache_file.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_include.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_resource.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_file.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/block.textformat.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/compiler.assign.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.assign_debug_info.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.config_load.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.counter.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.cycle.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.debug.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.eval.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.fetch.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_checkboxes.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_image.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_options.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_radios.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_select_date.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_select_time.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_table.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.mailto.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.math.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.popup.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.popup_init.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.capitalize.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.cat.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.count_characters.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.count_paragraphs.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.count_sentences.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.count_words.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.date_format.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.debug_print_var.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.default.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.escape.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.indent.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.lower.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.nl2br.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.regex_replace.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.replace.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.spacify.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.string_format.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.strip.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.strip_tags.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.truncate.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.upper.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/modifier.wordwrap.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/outputfilter.trimwhitespace.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/shared.escape_special_chars.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/shared.make_timestamp.php create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/temp/.htaccess create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/temp/cache/.blank create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/temp/compile/.blank create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/.htaccess create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/popup/popup.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/popup/popup_centered.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/blank.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/command.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_colorback.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_colorfore.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_hyperlink.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_info.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_picture.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_smileys.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/popup_table.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/select.html create mode 100644 sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/templates/wysiwyg/wysiwyg.html diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/demo.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/demo.php new file mode 100644 index 0000000..ca08220 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/demo.php @@ -0,0 +1,35 @@ + + + + + +PHPDevel Wysiwyg HTML Editor + + + + + + + + + + + + +
+ + + + +
+
+ + + \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/readme.txt b/sai/modules/saimod_sys_locale/wysiwyg/distribution/readme.txt new file mode 100644 index 0000000..e07667a --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/readme.txt @@ -0,0 +1,38 @@ +PHPDevel Wysiwyg HTML Editor +Copyright (C) 2011 Ilya S. Lyubinskiy +Homepage: http://www.php-development.ru/php-scripts/wysiwyg-html-editor.php + +License grant: +1. You may use the script on your website +2. You may use the script in your web application + +License limitation: +1. You may not distribute the script except in the case when you distribute it + as a part of your web application +2. You may not remove, hide or modify Info button, Info popup window, copyright + notice and homepage link inside Info popup window without permission of + the author +3. You may not remove or modify copyright notices in script code +4. You may not remove this readme.txt file + +Installation: +1. Upload the script to your server +2. Make sure that the following folders are writable: + a) wysiwyg/temp/cache/ + b) wysiwyg/temp/compile/ + If necessary, set 0777 permissions for these folders. +3. Add the following code to the head section of your html page: + + Be sure to enter the correct URL of the wysiwyg folder. + For demo.php the relative URL "wysiwyg/" is used. +4. Add the following code to your html form: + + The first parameter is the wysiwyg id. + If you use several wysiwyg editors on the same html page, they all must have + unique ids. + The second parameter is the key in the submitted form. + The third paremeter is the html code to be displayed in the wysiwyg editor. +5. See demo.php for integration example. Demo page validates as XHTML transitional. \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/popup.css b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/popup.css new file mode 100644 index 0000000..3d00dcf --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/popup.css @@ -0,0 +1,16 @@ + +html body div.cms_css_popup_main img { border: none; } +html body div.cms_css_popup_main table { border-collapse: collapse; } + + +html body div.cms_css_popup_main { position: absolute; display: none; + +font-size: 0.8em; + font-family: Arial, Sans-Serif; + } + +html body div.cms_css_popup_drag { border: 1px solid #000000; border-width: 1px 1px 1px 1px; padding: 2px 6px; background: #802000; font: 900 1.0em Trebuchet MS, Sans-Serif; color: #FFFFFF; } +html body div.cms_css_popup_body { border: 1px solid #000000; border-width: 0px 1px 1px 1px; padding: 6px 6px; background: #DBDBBA; } + +html body div.cms_css_popup_drag { cursor: default; } +html body div.cms_css_popup_exit { cursor: pointer; float: right; width: 9px; height: 12px; background: url("../images/popup/exit.gif") no-repeat left bottom; } \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/wysiwyg.css b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/wysiwyg.css new file mode 100644 index 0000000..a1a4af9 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/css/wysiwyg.css @@ -0,0 +1,65 @@ + + +html body table.cms_css_wysiwyg img { border: none; } + + +html body table.cms_css_wysiwyg { border-collapse: collapse; } +html body table.cms_css_wysiwyg th, +html body table.cms_css_wysiwyg td { padding: 0px; } + + +html body table.cms_css_wysiwyg img.cms_css_wysiwyg +{ + cursor: pointer; + border: 1px solid #404040; + background: #F7F7F0; +} + +html body img.cms_css_wysiwyg { margin: -5px 1px -5px 0px; } +html body table.cms_css_wysiwyg img.cms_css_wysiwyg { margin: 0px 1px 1px 0px; } + +html body table.cms_css_wysiwyg img, +html body table.cms_css_wysiwyg select { vertical-align: middle; } + +html body iframe.cms_css_wysiwyg +{ + width: 500px; + height: 250px; + background: #FFFFFF; +} + + +/***** popup ******************************************************************/ + +html body div.cms_css_wysiwyg_popup_info { width: 250px; } + +html body div.cms_css_wysiwyg_popup_info div.cms_css_wysiwyg_popup_info_content +{ + border: 1px solid black; + background: #FFFFFF; + padding: 10px; + + font: 100 0.8em Verdana, Sans-Serif; +} + +html body div.cms_css_wysiwyg_popup_info div.cms_css_wysiwyg_popup_info_content p +{ + padding: 0px; margin: 0px 0px 3px 0px; +} + + + +html body div.cms_css_wysiwyg_popup_form { width: 300px; } +html body div.cms_css_wysiwyg_popup_form td { padding: 1px 1px 1px 1px; } + +html body div.cms_css_wysiwyg_popup_colors { width: 161px; } +html body div.cms_css_wysiwyg_popup_colors area { cursor: pointer; } +html body div.cms_css_wysiwyg_popup_colors img { float: left; } +html body div.cms_css_wysiwyg_popup_colors br { clear: both; } + +html body div.cms_css_wysiwyg_popup_smileys { width: 224px; } +html body div.cms_css_wysiwyg_popup_smileys td { padding: 1px 0px 0px 1px; border: 1px solid #000000; background: #FFFFFF; } +html body div.cms_css_wysiwyg_popup_smileys img { margin: 0px 1px 1px 0px; border: 1px solid #D0D0D0; background: #FFFFFF; } +html body div.cms_css_wysiwyg_popup_smileys img { cursor: pointer; } +html body div.cms_css_wysiwyg_popup_smileys img { float: left; } +html body div.cms_css_wysiwyg_popup_smileys br { clear: both; } \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/popup/exit.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/popup/exit.gif new file mode 100644 index 0000000000000000000000000000000000000000..b61afc4e484c400551abdca8a8bec302fdab96ba GIT binary patch literal 60 zcmZ?wbhEHb+`^FD!;n0OA$co9@-c?wa}3!n4B0&l*~b{NuQ6obV<=wA zQ2ZQ-II52^R0GNPKqSxt1m_r9fQ;`zB+>I-py$8De+GvCqhK@y1|kF$f3h$#Fz5gw z5PCVuNoZi%H3k13Q`7d8SHpXxvO-X1gG+U{kOl f;mctmHi?i84;q@9n5M^Tr_A`h@O={_BZD;nL#y_a literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/angry.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/angry.gif new file mode 100644 index 0000000000000000000000000000000000000000..e68c5c5195aa2df1e95b704f91c84c86632a0dbc GIT binary patch literal 465 zcmV;?0WSVWNk%w1VH5xq0M$PL|MDo@l>+9p0Gf&mmUjzqTLprGg8J7C|LGy#-rn=g z1H{C{``Q!#?k4}`9yvKVSy@^B@dOta7X8rz{K5j-u@3CQ0PL#({pbn$y8!>=9slMa z;-mon%>gSU0^pef0001d ze0=-+`~T}B|MDF7)CTs&0K|(8-oFmw%MH7i4#cDn)u;`vbr0pQ0O+9r|J?w-vJQ)j zi~s-sA^8LW002J#EC2ui02BZe000K=z@KnPEE@%itN%CX))mV{jc8 zkOBr{LO4(pN&&JcCM3NG0MK|LHlqW@CP@%m19Ec>2zMGH6Bz_8Lm(bd4!FOiijqcRsH4?+?Lbak$ghbI;n9}>1PCXEZF4c zLf+h^Xh86ooLp~Al>ivOM}{eP+^l@|(;KBL(roT;5=;w}xj36^-9(|crzBsWlA1fYB0G??HcRaKX0bS5 z;fgfTmF@h`_K582f%LtZD@Dj`N z<2buY(?)3`?0U?75s8b;oCjM(q!|SYXoNGv2UNicXbg@h7U(ss@0TYp5i3a zb91=oPp!JUULf0_m*wiFj6Qn;1NH zs@yPWU}%#v+r|-daPfr3#U5K7I3^ruXcfw2QWWY)In}`I@lu0vgXsZAMjp8ZKa@9| zlNRG(dLhBWaG-;!!B@aQS*_y$U-Abg#f#eu<3(Ateh4Z~I6HB3xP*0`%yzC+x7ukD z1_B4zC-19go?g+I+J8XCk3+=QU^!>>65sg}zY0AR6!n9Qcvf^OaJRTxi=I&sN^f=G zGrFL$W5K~CEJj+Q9EFU}SlSy4+Uy=2oY2I`$ix$r!0?30oo4}y>$eS`7dW-D>zAqQ pdiW{fsF}u`iSCjCcNQLZ7dD)9fnDJM12c!b%ajK#Y^*E{)&SVoNSy!x literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/arrowright.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/arrowright.gif new file mode 100644 index 0000000000000000000000000000000000000000..b50ce59827fc9a7d9e4c38405e8eda002493cfa7 GIT binary patch literal 1117 zcmZ?wbhEHb6k!ly_};_dY$EXgnbMEjazAg&e>^Xh86ooLp~Al>ivOM}{eP+^l@|(;KBL(roT;5=;w}xj36^-9(|crzBsWlA1fYB0G??HcRaKX0bS5 z;fgfTmF@h`_K582f%LtZD@Dj`N z<2buY(?)3`?0U?75s8b;oCjM(q!|SYXoNGv2UNicXbg@h7U(ss@0TYp5i3a zb91=oPp!JUULf0_K*JE-rNL5aU&n5%EZL60wZUkSJWN zagv3LUEJb_l1BpzCzDCchC{~>HZ{pz3lL0rz`(@9&cktHfkKZIKeOc=4Wk6-CI-eG zEFK#Y85ns?b8-ZCG`TA>yH9kwu<1%et57DBqEJW5sRm|`txN$<&l?!n_yhh3Mm*=` zW>MpMAEBbOpSR@~ z&8SHYkp25e@yXN2ckkYK|LM#7GmBBjxPZy=CQVv|rN9zpRP(#&+?0>jkb{K6PU`Z(4xN%j1%VmWWnoIefk% zdvAllq#~ZBvm0mSv(KMekr|?pAHun!jsNCy-kWO#_D$g4-NkwJ%9+V+skhe&T$s&u z{o478H0um+j`U!;Wq`C0SPGn z=k{|A33hf2a5d61U}gkLDgI<(J;6}TpaW6{iY5m3{|(hm%`L5MEdm|^R*H%ScBTUD zO?=#CNd?6v(S|zQeC@LGh55{EY|IKG`nK}2t^9eG%q;Ajoa`*jqC#%yki?gpkflW7w&l{1*wB!x5@3|#dYSUHme)^wV^I5=5f=7Nhx zfI<^1Uul5LPR5=Ia#}fEDH4WC%>2>`hwda6t(YVw>L&T&iRGumCzpFxE6n*YA?a|N zh@79tA@3al3gFP<0)-X}11keJ13NIZbQ`LxIT#q4+M9qu#=yZ+&E7qUft{I?aRws; zWAzL+&dJ@JY}J#OPHFG%XlewTkb-K03eW_`mZr8QMy4*t=GM-x?g=dum^!Pw`zK9m cp54;Z(b`@O(a3uMJLt1|z?I{mU6{=x&se2Iqz%c2882-E<|I0DyxE#7+ z6951IA^8LW002J#EC2ui02BZe000L6z@KnPEEy1_px?2Ll~7LkTW{Gc+_QDUvfE z1RE=TKL9u*f|4{PC89F~FpEMKJ#zw7! Yh71K()bJAJhlv_Xnmnn=^GFZ?J0ID}yZ`_I literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/blush2.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/blush2.gif new file mode 100644 index 0000000000000000000000000000000000000000..56004c395bc475546074047d22262996ee0f49bc GIT binary patch literal 1152 zcmb7@|3A|S9LGPi)l_QHoIM`4m@p5Sy42bs+kD%6%h&SdV!o1SP#~@hwnN1 z@^E*)ERILt0-LiX(Z-@AB_N%W~vhB^A1Yb)&|Az5f8W<9?9DLRZ*AJ5Kl9G{M!p z>RS=^n)=L}2}%w;J8(;2q2k+}-br1)#Q4RNiau~#t6`yI^b=eQXo(vYla@O1I`tOi zz(bH9#6*EQweiBom1X7nOQ9T?v|Al8mN-}rKfHG;i1!pA1IS7jZASB}sd*6Csg z4j& z8OQ_X%1FPtF?3hFbU*R#6cE-FW>`fsmK3tmk6_mlpAK|m9~B(@%s!pTzxC81cZQ@jCTp=spZ>LP(4Gm}`UfIHM8VjL?k`$sg`$t}05! z?uDFZZr3*2-^w9?((}okdQ2{unOmqy3SVg_>GJ}iD+m#8UZYi}~)6@4*bSGf=SMk)~-rw#T!fN=))%3RxG zrB;u8So*K%|2MjpfctDXe8%TbAclb845@;q8lJ>xi+>`5bHA{GNTHHfyK_qYyjaJ$ zy$*R7h(uFLN~=trjoYUh+BhlCmPkGfCChS)kK`EGym=GhvBQ@VjF*a$KKhaS2<{8| z^Bq=K+36H#!J z?KY9hwl&fLZe{P6i=LHwoZdF`l^u(-KS>^XO zi&EPAzC7$(;gr)bn0rLE_t8_c2${+C8)RXDCC8P#xurR7FqgOMO6&VFd!*gQKAN|l z=S-D(Zsa!!J*_ubS{2cmVR$(&dY;~A?&ROApdHHeaNoZTXPND6;=o04n*>3H2)!*a Ih>N)V3lWGZF#rGn literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cap.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cap.gif new file mode 100644 index 0000000000000000000000000000000000000000..2eb6aef0c84c470c15a3630a8c2c1a8bfec0fc9b GIT binary patch literal 704 zcmZ?wbhEHb6k!lyc$UHd1kNS`@tz_%e(V|E9GSixxd9ycA)NVPT&V%FX#q0n!E#0M zhQ*1-Jro5^`@F877m zTvz6EUtP$3brH{v<-9k6XpO+_bpm(S3*1{TaCw91jqT$1HVE9?C~$w1;G^wAkG2ax z*(LIHx5(2yBF}(mzu5C55-$&ly*?`b`k463sNWQ-)^WmJ-$MaI3E=qsCBK!54 z?6>Q(KW@wYye5`M8U3@Tdjl)bNB}DV%)tFZW^{85L!JX|;uR24?)#A2*XCc0!OEIQJuqhuWyA|RM{ zVLGd9gNWm%6iy*!hpas(7Ci7)(&tq>^WfuS_I??|Fpq=_u7Z*V>Rd4ljE7sLLZv2YYLG@X`kZDe4u1^_+@4QT)X literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/closedeyes.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/closedeyes.gif new file mode 100644 index 0000000000000000000000000000000000000000..aa1d95e86d9f050aa23d3e5cd15f7254d69a2570 GIT binary patch literal 472 zcmV;}0Vn=PNk%w1VH5xq0M$PL|M4sAwE*0d0tE#H`|1Pty#SSZ3Z0D$bYlho#j) z;;jJx=py&l24q47-`2EUOA#{oG9`;4q+lH# z6$If?6Ln~r38LaCHdL~Q4FC`^I*`pIrfLvZ2Xb=}b{z>27zG9^Lk%H<0E7&8hYJ${ zA$~s!fi?pX5d$3q2?+xj5*Ld?6h1eR0|S(?BN#ImClo>|I)ir|z=tCmw;(FJ9yOqo zz=jD65+*sutUfN1!KH{Z0Rk|(KY%*S&Xv&|C@G9TjwLjuhY%wR8Ybu{nL~gj8xZpI z8d?MZk#3!kH#{a}*suUqiwhtG^ypIr41x(03KR(N0tAQ;Y>rH+f+GN~6kNPS`9VU# Ok|ryltej~i2mm|PhrNOT literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/clover.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/clover.gif new file mode 100644 index 0000000000000000000000000000000000000000..67b01e704984a47426d2be9e9e2ee0196188e71b GIT binary patch literal 1156 zcmV-~1bh2ONk%w1VH5xq0QUd@MOO&a+S2Lm@J7lJsIrt|axpz&5S5{M%F)B!;@@C! zE=<)Aik4|Pq!v745paJ+JH#7A&=NI~8;O=_a)3x0v^P4s8dGE(JGmLc%DGf!9@pL1 zIKv(wUK}Z{DJEFQ3~4noKk(%8>S(G4?>7ki0S=<$R8h}F*c+ZMbQ{LWfDNi7edJwF2N@`w;L|OC^*F)bAd@Y!yQ0f4j`N{KU@wT zmM}QCA4ts-PudJNq#QcO8$-wxG{qs-+|?SPHh6|m;^*clcpGJPHWIKtBdssQ%)GF< zpGVRYM9dQ#wKgZbEHi%|EQuq=&c8;(5ge*D8m%@ke;?7;&M15)M$#0!!>=sACq&T} zH)<6qwJb=}5`BtSDz7Ox#T`S*6exrzGKv{Bq!=KJEl*$;HN+n*ffpx(CzqmpF^Cu_ zzbo$Y_W%F@A^8LW008~~EC2ui02BZe000R80R0IZ2#Y`gYuZ>0T*y!$0d}{x^a5~! z0gQ(JqWMu2Ktq`+u3C9mWRF2Z1c1K%0bne`fJDBE^yAZ~;S4LAsswxEq7@&bp7AxVYU ztiy*b85scr#lUm+48;OlX&iNEfMib=E!_+x5cnWeE;?;3UULD!c;CRRVzK#DWj8cGdgEK^-{&YZ&e;_eGw&C)@0VF_Xz# z4OC+oQeZL)f|M1EhRJ%=?$Rj*Ef{uTn)fOXv>qjZt>Mr;HbyK7 zLJ0sNM2#@C!4WwCV2U(C5EDloLySX;J`>P@Q2+-BazFqG01(0tI$YzxBp5XmP6{C0 Wp+q3mgxC-dM11m22734t5CA)%n8ft} literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/confused.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/confused.gif new file mode 100644 index 0000000000000000000000000000000000000000..23b00de1e583cab8268313ede036e2323b4e171a GIT binary patch literal 492 zcmVwe#2w+PW?5hCq*cP341pnqD?#cuH;~$ZPWc=9?|KuQ-X9VY)0Q=$@ z%!LB*w*cal0M3j8XHgyb*${3`2cVaHrE3FnRR`DC)BD#A-aL%-QL~O(8_RLF#qBmUr80|q5%KpBKp(_=cWMs+ZVfc0{q+({NWz~0SN!) zA^-pXA^8LW002J#EC2ui02BZe000L6z@KnPEEV&a?_H1c*M@*$$u_z(1t`FDw;4))Uzw4IMQk3_<}a2@Nj< zo3at$1HpqRA%YAf0N~;ffgTYEY9Ik=NSqcO4!Cfk%|!KeD>EJ?(y>P%o&n}W9!BjcxOD(&&6L!6y>`V@Xi|b)*a%v6951I z*x1qX(Hqp#$>zKi<-8Q3mU`s66m?@Z)u9V_W;$X`8Kaqg%|x5zZRdBc+k$oiDU6fbo`j{FfpcLq;kv3hBog&YcT-X+OJ)31~|Q)YHmmQyy$n3Tadz*VfOp zjSiugd(yHNZBPi`vJtS867SI*X-x>4ZwKD55a+}gzK{#m)Xcq%38aG$cxF43hGp~A z9nGo~-mwsJUor3U^LuJQ)SnB$k_-RlB11F~_4)k(0000000000A^8LW004XdEC2ui z02BZe000O7fP8|3goTEL2yIDsCMH=*TnLAP3=UpAV^unHZz~QAha4kOX8`~J0T~!5 zIU^i}2|q#s0tN*I1_A*c4PjpigLZLd2MYsw$a(_{2LvBD5)gt;J8}Yh*n4`}dk+&$ zWEFy9L);tY+&3YD6gB__+}qgz1R{A9f(lpf*~#SgL(`Eh`@w}Kt2?n zJP>dU;Q#^N=(vF+CO%WDoIrGL`a)d@5Fo!Ck>A~g& e9xZ7VwtSkz2Z4tZB`jDdal(Tnx_}D>0suQNbR&WQ literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/crazy.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/crazy.gif new file mode 100644 index 0000000000000000000000000000000000000000..9c0d20dcffb612e5219e9fd74feaf31043cd2f7e GIT binary patch literal 1025 zcmZ?wbhEHb6k!ly_|5nzLn$oR)Obx1>SEJ zcn>6xNxVNN@%@;()|9M;r}(o|MwLCKL;Ys|L+<8znA#`Uh)5X&Hw+O z{~raTAwb6vQ2fcl$iTqJpaaSYpgh6AagTwSL&jsn0>@@FAfu-ddn=*Ei>I%>$l*!$WQChTLKa9~PFrJ}WM=#I2&?U<#UAphnf>^7Q@UA@9r??(y>W*B$cF8|1naVN4h4!WNu$3hTxf z(a*(SNfhP06#CvDdTBmoP#t(@Jn+sMq?>@=un?r0fB)qo{^cTE*Z=_0}Dj zZU^+$9p=0g-meg8R3C9z3!8rsw~!8@mU@(P3}{pxXiNxpWH@V43FNvHYfcBBm3WI~ z2gaxtXHp&9uMq3S7kOws(9Xo~%^IbG4PZ+at&bAz%p0kP52l3=&YKI^rw!83$GDIV z(y|u4kPEtr3Gedr@6jB1W;^G=7QKuKl7?iSc?-^&32#&hXHp!QZU@nu3YCdynr{cJ zd&hDBy%ug%3XyIK)u9X7xfp9t2<^%lu8|VWsub0t z4Ah?stBn!Yvlew@Hlvw+YEB5*tPu72{Qv*}000000000000000A^8LW004RbEC2ui z02BZe000O7fO>+1goTEL5f3CF7#JWV4-tog2oP#?P(^QXOF9q;hYJofR09nS11uwH zHVzAg3^zXm1^~9U0~Q%iF${wgD{ul5009BT#{vZ&Szl9v95ODo#>dqF6&pcrPJ%T^ z0?4akO&Lakc|#$_vUrHY^)N(u}+aiHXZ6B3lYCkp3Vbf&=g+UCs&;TH0!Z;6O0E7YJi;$=_c@kW>kf1~pEk0Zws)R>F e6ghJhq_n{CX_B5qCPZ}TAi_i>yMPS^0suRm+#>w| literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cylon.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/cylon.gif new file mode 100644 index 0000000000000000000000000000000000000000..f4cbddda14e86e84c20660e2784d1a607792cf5c GIT binary patch literal 1695 zcmchW>rWI{7>Cc!%+B6t=A4Vk`MTcs%~P=o~m zr4id8QUtAdL#)vf1tca-pn{_H1DJY&wJo(`Xw+6)QL%}17Ng)l(D^o*C(rwPe`ijl zDIzc^l>;1j=>RXsU)21CZrr#iHjZ7Y%4eR>bc|L z(7s1-0)UD$CE+`RYM!zO{$cIE(6!H4LvaX30M|4aeF`^slI7nPXCK_?vlG8Ic%||I zlY2utH)E!&T2(wqEk7U#*^ecDEsi)uYBmZ}4oh?TWMK`swnnt2ag*r;UUHAx+$}TI zOTu%-KRWtiPUG{lXC<5?Qak0|nKQjJT_TTSULnHBW0>c1;`6(TqPx^i2j#V#m|+zf zii2N_k3}9P=V!Z^FOpk&r3q(+>o18id!<4-5K#i;i-i>hZttOIWr*hFhzfpE>7?NsL1@9!#Utd*wLGSJAfsWcVLu`vimA!KBsj%6bd3PUIovhk2!!tt-HUI`N*okr8~kTEFX z3JzKz^D)O7Ib=kvi9-gKO@c56G8qh&KrwFwf^;5c*jO5w5Q<>gOa+xq(Ww+QL#<4K zOgw~EhPEpxBa5_%H6TWdcnPeQ$RZI;q|iEs)^jMFWi1S?)tDimYDl}jGBbHQnL%jpYqua{yX ziDoomqyZP*(aw+itrwJ*DfZs$R9Qek4vv|RgJV(EBt9dzKccN=;8<)514p~}9yL@Y zn|y9bY674~oBO4%^vW(@wLur7{Gz^j)tUU3N8xP=*N{~Yk%QYkh+^`ts- z>^Oeq;jj=>yAyTpdA2f3H+yb8s>}0PzzV;cQLp~hG!g+e|F7~r`eWt7I}3B&%%v-( z%L0OnV4yecD)qPBmxJ``D$n5Ze5TJr%NVKFydPR4X?;qqRnt@2-4zrV>nq8-dVSA= zs6O+OYjfs_;>tWG%1w5l#}ua5qn{SEdK_8mlVM*lAn3hX@thO8FxpKno??YOD*+hKa!!`ZYV3|4BD@ne z<+^y=rc235&?(h`_Dr9oQFJnTub0H@l~mbmsv}k&(lAq2F%JtTtqR`iLu55{g`MvZ z5>tePCx}Tx<|NvpEk~25kCVPPP|ojG--8{Zil)`FY0*WKiJZ~ZU{-u$@0t2`5#9Dt zTF>Ky->s(`GN-d|(>qxe@U*#%NY=E89BrXP9Z!;4Q^oDmlR4XyP9{?Vm(@cNxh^d{ zYP+A5>sVYqgke)VOyBaep9@=K9P>64AGn;vyDis*-fgxG=sqabIZHG-3xbPPul*l& z2iQ)mvK>#4TdSLz;|%}KvW~YX20ygm{C9Hlyb-WT@Y`990fyGRP`}RV)XVlMjT3u& SD17Ci`AuhsyUO^=L;eF|E5eQd literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/dontgetit.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/dontgetit.gif new file mode 100644 index 0000000000000000000000000000000000000000..d7a3b8c4b531b2180e6dc7abfb48ac4059c9bfbc GIT binary patch literal 695 zcmZ?wbhEHb6k!lycvi~r|Cy4riNL=nivOM}{kSdn=b^&S+w%XPD*d`E|M9$3ae~p$ zAKxBr7rKA@;@?M#Z(lumc}Q&OjH=t$Pk+58`~HmNv&Xl-U6*~jN95B*=_DWVC%Z&` zeE)K9gFu3p=*=s~SI%qva84>UK=#)?`Kt@LSI%vCeN23MXIgcJO-+{FoKmhQyM&Le z5PN$@`oJXaWv%=x+xg$0m71Byo)^M(ZVva`Q<7h<%4UVi@9O02PG!F`pF2N<^W1Fi z=Lf{*RdQ$eaO{}CcXOviqPO^yy<+#)3uFg!UR}g2h%B91U6E?>W$0C)=d`*dUAJsj&FiD$H`fT< zT+TbYULf0_V@fg4%7GMwOJ;}o|o^lp+%HDx`1;uIr0tC(tWesGg#Ivdlen>U$Q zM0hkao4g#9m|uKjVCLY|(oJfT)Om5&dAfdMo1`KO>&m3O1)ECWmZ_|9ZtrQ$X5Lx( zxIwjhfttRM$l+yg7&fzb+zJR(UeV1bC&6=N*VJtB7R9g&6#`otyM;Lv)C4T1aOpF literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evil.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evil.gif new file mode 100644 index 0000000000000000000000000000000000000000..538b96505c5b1d54d05167680849da5bc76b7fb1 GIT binary patch literal 1112 zcmZ?wbhEHb6k!ly_|5U3ZCIa!EB01jdxxVcAzU+B^>aksfwG0c?8V{i1#t$&Nv5UA=4Gi?vMGQXB( zX%_R6Y?fs?%*zT{*48oaE@%4B!0=Ct;a@KEnnsrOEzIk?ST^=BPiRh>(2_iG0!)T#y3YZgwgJ=D!~s)gxX8{?U7rt`gwXQzwbpUQB5I>VJ^OxM>j z-CM_ae+%P-$qbLDGCZ5f@O%!#zqt(0modCt#PDh*!<$tMZ&owBUB~c#Bg6Ym3~zTb zeAveDVLQWz9Sk4$Fnrp}@cAIary~rXk1>2X#PH=X!k|8~%N)P1aQ(i{`};cI?;HHTZwmarCHUv2;NLr9fA5O_y(jVS zzSQ3bQvX0m`rkvDe~)DUgOJ?+$MXN5DExn-`2Q&oDgA#2M9Tl4EC2rw43beWkRhP> zlZBCiL6SiS2hOeM*L`n+_zfHP5v!|L|a^ zFgq`shD4M=i^8&AS;oo_PcBY=-p61RK0!u;!?{(`GLH4d#m(yd42+rE3^)~?AFwE7 zzv58%IE{b)_L{vmClehLn6xXuPkL~9xxbuH&3>DQ3mp`iw9=nFczOG{|NQM)J4|i{ zS~j=Hr`)-7^VE)wau%r@G&M>ri}?r!4EvN2uQw9v9m#l_9SLL#wQP|bgyNnnvmM;iw_>pl$u fCiaPnW;G56xPJc+;v;QNY^3fY$OBe9Y8qd+s@5~wL!WNu$3Uy>U zje%k7#uw|w7uBH)`rRL#lY4e$JNn)q_SYR_PaNgE6vV^5-mnn$)*W6+6r7WKnQjO4 z)g9!$7MYNCjDTRNhYy;Oc$#kq&YTO`rwzc83)#6CnU8gGSPPME3b>FC(VGgJe-PQM z5OQEN=fD=u(9X@O6lYQ#&YKIKc?;dI5W0y8&Y1~lObFz<6Xv`WWl8yMQ+^-PVvlet?In|;Jy^sr~f(@;Y5@%B$b!9qpVK%Fc z5!j~ft00bsQRc3-GIV}JJ0LjSL03B#o zQGz&b#n{>B+!zcRGJsWIb)peIg%P&iQQR<2zc#PA?LmFz=}w{*8&s&+up(03zlH(<06S0|8}k4F literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evo.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/evo.gif new file mode 100644 index 0000000000000000000000000000000000000000..cb51b93f4a30f39c141b3a76168c073161fc1d15 GIT binary patch literal 700 zcmV;t0z>^rNk%w1VH5xq0OkMy0000(G!S1&6l_ihXiErbO$cI58EQ}oZBPhoQwncX z32#;kWl$YvP#kAd9%)n{X;mO{UomrGGj(G&cV;?xW;=LiJbGzAdul+5WCxFJ3Yu>R zl5z~2a0i=l2cC8cntl+Xd<(682c&}!rh*Nqh7YHT5v`9Bw2cn7j}E(v3B8O7zK{#B zlM<4JW0QtupOtu_mU^L=d!m?pqnUodk_*k63(lDd&YcU;n+nvQ3&Nxo&8igDp$pZb z4A`d)*{2QJtPtC-5Z$j3-mehTuocp>7TC8J-mnnfu@K*~5#qNJ;}W zB1K4#TV5@@Xi|X&l>X48}rm1_0}Es z*B$uV9{JlJ`rRM=;UN9uA^zkc{^cV7*w@h5*wNkH*yQEo?(y>P^7HTV^#A|=000000000000000A^8LW004XdEC2ui z02BZe000O7fP8|3goTELdU9+S1_l>vae9Y>cQXklMp{@rBL_2ghjkMmTViBnVqjcQ z920egb`U#aWoKw;XJukuR45O2gLyA4V`gb;$ZBb3V_i`pE_i}(3twdb$=JvMWL825 zZh|r=VrSZF=iFIKA2EU!M`UQp^lE5iT}?F>f(%z=_2}Kphl4@CDdhqpJ0m6w6B`Ek zSSS((z_EI1%2Z6UqJp3pCAy3Wa1q(Ekx_tnfFa0@0x4d^1h9px%t$IkatvrA2#*UA zRJec%K(r_oB|SPs8)U~piYHaFbm@}C%99~IL^J?Kh>ipeL6$givINPG8yOdZ4o=kCNTL9#+??ksnc*-mAoX>n%e2ILe4 z5k+0h2Xx?5X9>CuU4H-rYT9yoMmdQ`>y_tz5j#P>veB_Vgh%&mhSsJD?r`!xd$`O zx!G5Gm~s4x>H#%jsF}35^bB=xMAm@W6TpwgQ7?0PYVtuL2)XztVbE{XBD43SM~_io zAZqh6t7U&Hpgje~^>6?3{rUO%`N}Lo?XlF=UQWULfEqonYM9GC9A$cpA=j@x6>e71 z$0YE)25uBV;hvBuWpG>=d?Xss*F(HJ+ZIp^E{>Z>Z)Ivh04bEctZTJUcz8~rjTwZ$x|I=~S+z9}eAoLC2 zn@<3SAdkcpSX$#wQ$hr3LE_Q4)2xGQ5BuD8Si*+4qAi)KdJ?(HhPCO&;+g(9&bB)w z%Bp?dUg7f0!!`v`asU%-bB-}69^!W@mpZNl05l!8+T1+ODTAr9NZgjnHeaAKXo-8%4x(?B*zTMkGf|Ki6qS8%d7491CB&C7W0m5;L5v0DtD0q6m_T z7g`$5^^@Cp{x~}q6V(O}_H2%F53JEUYKcC5Y=Wb8cBop=h}R452SrpHgBq~Qq-}({ z7Wd<#Q`!2t50ez0=}p3|r8mkv14JnmAuXi}A!A)whS1mCMcv_TD%B;D1G9&C2}CiQ LK&G>3IK=!1Nko$F literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/fear.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/fear.gif new file mode 100644 index 0000000000000000000000000000000000000000..38b9539323dbba626e206e93aee0ada6bace97d8 GIT binary patch literal 652 zcmZ?wbhEHb6k!lyc*e-!Y$EXg|9^cI?*Gq}isB8gTsnFE+W7_3D(~LC@&417Cr=-} z`}pbOd8uD_$2x&ay~yGmhI0mwKL=Wr_V1Bi7lK~ zb#4y#%{2nusq8m*O59m5u%?E6Qd`RVGm_~+vNQA8XXUeJgvjQHa9%ifq%_%V{?v+< z?fiKmT-P^?W%zI`o>_ZyIq%*c&L_J>wol+IOR+dGiF;lp_tix_uTM$6Jta9YkL&$e zsa>6%=|M6VXLFrhB~qDTn;9a%wqNMdh2yJx1(&t*zda-U^R|3;AZLQNSVfxkx!K%> z5!_eib1$4;J*AlE$u8k+KlY_fyifOt?3lp!_2*v(>H)={EQ|~cj0`#;BSCS(!2Ys< zv5AqPwYjO4p}oC}lT}=bk55XRm9wk6iHqGfRN2QXAS{xdYbGNbOD8X{KxYCATQ`UK zj24+~45>jJ&D;{(I=UI$H8h)qVs|$0G*Ay|(hfe@a#&W*p~+QWa3}LloFP5|Wz29C=N z%p5Wv8x}Y=a|!TBG&meQ*u=$WvBDsUrIn3c#!lry!jaB?1!oh5f(Z>Q6Ey7G8XP7q zU}D!`Ji+pz@CZAb6sz2aAA$}nLMloZYy_K{8yoc<&&7Cc*6?fO(E8%Da?1-A7AE!& zOSp<$F7hyM%6nRMNSmEIky&AZK=8B9nTl39JG2Zk{by>XJ$pJK(eWI!V%0JUo`iyX zykdPyxdKTpiHF)4Q#>XFD=>1%I~|xi^P%JECKibT3EL`XHf~NkWs?I5hhB1W^MusR PC`dfqzN46(g~1vCA*Klc literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/geek.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/geek.gif new file mode 100644 index 0000000000000000000000000000000000000000..2453f145c3e572fd7a7e04fbdc6ca738e5ce0008 GIT binary patch literal 676 zcmV;V0$cq@Nk%w1VH5xq0OkMykEH)YG!Wh1-O|v?|K=mk%*6lYA)S(U>Fn=tUNG>s z0QbxQ?5hCh>h0Ip(_l*%=bQll<|6vk3S>_m@3H`RXFQ>oeay+Ww;2b_|2m0|>+ zm3qR90`Rv0%gMm;yZ~`i2iMoqns5YfO$T*jH+W_|^uqx9(g&}E1O4C{?5Y6Qt^(he z0PVQ|@VEf>$pG)M0IY!o^uz#ZQy$=x0Qk-V^vnjBYXtMZ0M3R1Y)c29eFXmC8vWiF zrD_A;l>m~4X8z$Fq0?&;Bc4azX zN*2w_!){Io=9vKJrU2BY0;X&O|Kc5xgkz9{V*cVC_Q(MB#{h0n2mjWXtT3L4ucH=0KLAvzP$lbDS{Wk!T`L;%41@JCd|vq!2upEf;P;_!OCAZ zf)Cr&-2pxmf?;vCvIOh_6jA7Ta&sY19d8B^1pNj(5^ykB0!GjZ9T+w^>0lsBga`)K zd{_WP#2FNVV91C;XG4G~BuLCUqJ#mJ8W#jLP*cYWhY+(qNLX;^3Ir%=8Vs7T#f1Vq zY&a|ka^eLK2qn1WA|xtF86gT3P+%a!2n$z-Dq-^6y5W$fVAdwNkkpLt;I5IpK56$8&Q_KcBFqt_qWLfr0=ZFAondpMa>OMwM%lo|Z=ggX19Fn>)(8}H3-Tc`R=j!d}oB;pkBVbDx_sanP;vLu5)Boin?5hBwmwo@_A9!ax z{oNOkgk$fq0PnH@^1T52*bih+9n8wXUr7|{q5$~J0Q=VtpqG62$^iP)2>#$3cV;`L zaRjl91D|~a^~V5pV>hI01e$OJoRW6_-x{xk1CoYj>Zt&qm3s2T0M3R1{^1?)w*b_p z0`tKD*RBHXxd7jl0OOSakb`2TYy)6Q7VN43ZcYd0nE>|50Cr_Mo|Jf$6aCy4&y4}?t^mx70&i0XZcqnpO$TvP2Y6;YuZjf1i~`@Z0cTJg%cKI8 zVg&lq2WV0qXi**L>+au|0Q1HGsCERxivs@N8O_VXtbqiWYXq%+1G{$ub5{q;$-r}B zHL;BYY)c2=lK}hK5NT5$_|FF3t^uWL1N6)W=cWK}O$YSC0PgblA^8LW004ggEC2ui z02BZe000O7fPaF6goTEL3=0_>6B8R53k-*X4hL6UKrl}}Y*+^lhYblYdkPN^Ct@i< zGYJia7Gq!vQ#BP8D;yyvAYFGBgAg5a3TglV0|f=gArw7mH)Vn&aCjWZ%Lo7n0{|+1 zI7n-PO)d&6$p``h7wbHBN**maf-znX70K)b{1+Nh6bw+=B51;y2glSAkid|DhGPcI zh!A8%#|Z!dj%n1G@q>_wf8^v*fiZx|lP3XS*s(+q4I3#+qC^RxL=h%};%JFtLgq}B zL;8#m1c8Vf5EOix1W+Y{o(>QOIr);tz>kf`jzoAv1{fhxZTNUFVBiCW5_Q73I#el3 f3o8*8l0cC`=hLJ=iBPa0L4pN}NOuDp3IqT$pzCYpFDkZ z_wJ2_;dZ*`JcDt6Me*g-If3MMDfoko)5Kqf2Ht#CwXQ z2FNa%Rsa8~($hU673nsU+fx5NQha$x?BjW;l8;>V0Eux zwjXwRTt7q2>%*tn)D&-aKHe7Ys9;uMAs!wfVOBdOe_QTm5rtfSMOl_pEV7FH z%5rK!;Y|`IIl_#$PP5!%3`tH4Xfh1tXFUDlE{hN=W1gs1lWLqM&z(Cwg34ybnN0#& z71AC7(S5v4Yu0cmWH2~0GRruXa4;`qQ1X@YnsdS+sX;oPCDm|I;9{44uL&GhN{?OL zC+lzja6qA>X@ap5Q_dF+g#)an3K~378GK8vo@Y{NW(}B1K8%o*L? z*rJ$x@ACBI<>US0A@$ZB?(y=Hg=6;D9e8Iv@Xi|Y(HrZ=7vi@PUr7|^ycFfU6r-7b zVoe#*7dVKZh>9N5>; zXHy=NhGp!@8Scy)&8igUzZPjt2*RWln{fy4^7EgScrh*O7n+mjz4tQoe=foJHmwVE(7Shni&YcUSgAd}j6Q!Gh)YHn&nF(xD z3YvZp+1goTEL3_4+492`Gya14in4GVHPYEx2FZ7mB8haVnuJ9hyAcMlYF zH69;@3O84G1O)&91q62$2xfK)gIQ5F1`Y#x$aw<}1_Bu@5fFlFMPmd5czDU#1QHft zM0RYMOc>n9eA5)CdA2oR9Kf`%>~PB;NZ=t&bGUoMm=aY2laI4E!gIaJAt hi5V~$jCfg+;?pEO3`A@QfdNB^4I(7n9b70706RvxA3y*A literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hehe.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hehe.gif new file mode 100644 index 0000000000000000000000000000000000000000..7aba10cabc8b0b9c00a633298f38f5d3d302a70c GIT binary patch literal 449 zcmV;y0Y3gmNk%w1VH5xq0M$PLMLP+VfE)GC9Q4>BA{++ky%gfK7R8<$|LH3G<0tvm zAn?W)K{EwCE(0DO9>~bZ<>lptg@r^!M1+Kd($doQ-Yn_B8~58M;II_cyD8MQC&HK* z9vB4XvJU#;CXsp=?8+MM$r|y~AD4j~_1PkbX%P71ERJ;+^wJ~h#TfqRDg5Oq{^uyL z0093WAgYZWhG!74nIfHf6zwpse;fSfD2#9vjBpd+t`q9W8tAtW|LQ9L|Nj60 z0RR90A^8LW002J#EC2ui02BZe000Kwz@KnPEEyd^~+5GX)!~ zl>sc6K0STXIy)twKZYnPD$zaC-_iv%4U|6-9||7c;NLzSFoaSBF9HL7B7Ge)9Ct%t rCoC)o0U||#9XVidSYu=ggBu47VAxQiL6;~(k}PTR1f$0zK>z?d(3q~9 literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hmm.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/hmm.gif new file mode 100644 index 0000000000000000000000000000000000000000..4400aba8ff91b10eb5ac3d87a740bce2f495fd7a GIT binary patch literal 699 zcmV;s0z~~sNk%w1VH5xq0OkMy|K%e7eeAEKCi-QC#a<>T+n z8D&r%{o*0-^7QG#7Vh!#^3fZTg=6;D9re~7@Xi|Iw-W2d7kFnp<-8Q;ycA+h8DB{h zqnUoyp$m0mHrUwFp_Y2l&&B1t6x7nmo^}d%W;*1$6vCtxq=OHVatz(C5WbKLy^IOc z(8p;_2-&O<&Y20`uMo724x4ZXp_hBDeFv?N5|3>Pr=En~un^|I7SNjt=foI$YCxxo z5$nYl*{2Q7nhV>m5Yw;~ntl+wiV4o03+cxhnr{bhR0)%YW$*IyiDU=Bk_)zv4%gPt zn{fxyvKFFz3(cw&@6jCC*U)lbG32}!?8zBvR3O;57i>-k)uIg0&ctm{2&J2WY*Pwm zP#kz>JEnpSXHy>T%o^Xa5pPxsu#*ycX+Pev5NTB))zr-M)E%gX57?&-)YHn;p9^S9 z2;#RBYETKEm3VVuGea~G_}d=;<|6g^{Qv*}000000000000000A^8LW004RbEC2ui z02BZe000O7fO>+1goTEL4Qx0)8X9R|a1Doo2?t<4QDsqssEVB%FDi%-Q6a}07)-1@IaJ97 hi4|NJ;uJw5=hGxT4MuP%v0+0A4kIMp9b70706PTW97_NI literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/huh.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/huh.gif new file mode 100644 index 0000000000000000000000000000000000000000..044edc01f0db41e372dd8837e95f7fbe014dc0b8 GIT binary patch literal 708 zcmV;#0z3UjNk%w1VH5xq0OoxF`rRM?`V zqnUo#*wJ-kHeX2;Voe#*&&A}r6rq-S)Y8d!W;)fO3!Zig@6jCV#TT@V4$Z0*)36oL z&cvd83)0ZX=D!x3aR+Ei2yIXZpOtvFj}Dt~2iUh4ntl-5t`Mez4Xuw7u#*yxZ3=Q< zG1;sTY*PwpRUn#g2cegHy^IO&%o^063#5Y&@AC6(P6uyR3g^TadTBq-nF-CB3%-yG zZ&V4`*U-+L3&4^KYETK^vJvdb8EH)jyNU_qycTCu9^$tXl5!05)E(Zj5ZBhv(3=X? z)XdeQ48o)pr=Em(W;=UoK&^cT*{2QZ#~G!Yfz;E=sD=;HvKEPC2XkRF-mnneuMnq- z5ouH)lZIv9uMpU$4Q5ar_}d=;^OQq05dY>P|NsB>`TYO@00000A^8LW004aeEC2ui z02BZe000O7fPI34goTEL31MVrARtU?YYB&f3=2SVZADfqM^p<8haDa`D0lz>coPy? zTpk^T2ti|b0|5mE0eX5C4Jva8gGh8d1_!!&dwT-L1R5?74uUUAT>}Dpd3o4*0s|2h zIWr-GLpyi@dwjZkx_kk64-_XOf)_Uc1$pYo?HB+ABBoprq#zAGeSG+&OXv@v6a@sA zoZF@?Tb_3hwm5;<=K_le){==-=Bd|*nl<&ftDH>Qam7_t3rl2CeGXeMkvag9zQ5-*gye} qohEJ}e0(`n>B@;GVvJxBBIDDfJ_$&0DDmM#2@WJA{asur5CA*G)-z`S literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/idea.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/idea.gif new file mode 100644 index 0000000000000000000000000000000000000000..6c9a51576b7ecad902e996412df5076008a80ad1 GIT binary patch literal 1046 zcmZ?wbhEHb6k!ly_|5&;kdSx;~J2$Rp8pad-v9I z0Ev6|onrA>*-Ofn$@NosUO>!oe1PJw862g9jShL`;GrA`UEQ zap7b3cyYrqh@DSLimk*z;t)fxtX;C=z_&vHG_kZ8V_s{3!`FX!yFNU?Hk+C-d zfB?kX0!SFpy##opTxu6mvcg7cf*tqJ*0RgoqH2$`-AjT&m^-$dpi_8Aa=9J%@t*4IY}w~}`&#V?je6MO z?IwcM^!u^Qry;@PcR1XNc;)TS?T zx`2Ac)wI$5STYQcDgBYuAQD$o}9`w48HwjTeA&C>h#AMbLLTqVbx zT&rlrf@HrxLDetx3|<(Jrhm&Cw#D7BCcbgOS00B>9MvDmN4zyQA3Gd0Q&e2%@AllB zy!eJMh>0KMJzoI;curCar;&#k@O%2$8{vq_NcJ#*pLyJR`JDG$N#F|=6>Fkwnyn_6 zAU-G6*#mBPt+Dm<9s7sY=xWII2e#xVL5g=M=qUrS#WaHjz(T4Ye4*TBG)SCJdOz3mf|McMDd>*DK#Ji443Ub);+G|^#DWTDww#YR<>qdBX_|VJ0xsPQj z^KBi5*&0uhB`YIj`CGSkL_^072(!0UI*kk)yj9=oVD=J`cXi}vYjyf)di6Bz%5x_l zkw|=9)w#LZ(jyX&F#*H7Xc;7}>pvSlGB7Ae4W87KZAd{@1}V-RIWplQeZTe2at2|x zx`t(~mVOLAr4gdhuRv`9t zXD2F!MJMRvMTFLVeF93f0#*Rn)$i3uf&c)-R{$##%2uTuicLCnxz`!SBNNlRpuSd9 z-n1w{0w>jIH@qP}AOSFcYbqDFPbWj}q}p408BoVQjRv>MXE5!CRrYc~R*^P#KgK~3 z2^!IMbkAB?9-=ijOgK==Ie1hdUfwpttFMMDrzHo1`<{#K8-o1mZt85q66EylvhB=U zg1=!VN8^y%$%}R#Vd!4BK);eTGq&Q4mNbgLBps*R!HwQ`6pvabg!n>8XqAub7ec%9W^Qom zPGw7h(QYtFO`<5=hRBBv?gG%d+^~h$hA3xgfW_YVhnYCJj>J2#**rI4IW0z>M0#1i zmezE#UY9VMtf@unhDjh=)i)866j59!gtOq@0fH2a|-#RE1Ob@h9x*6=gM(8ahMr40YR#IbB?EFA= zKzV;&MDgVY++8uavpXt@eWfzHqOqGXIzf@k^3cN!*5tq2qg1c6n7Qp$t`sD#WeiVc zbIckbj$YBj_s{Gp{Uudf)I6LbC-J~roX=Kk>EHQ<<6MwE*JY#k8zyW8_Epvubqdzd(r4L}DvmQR1sim#W4!~k~J zq~lURhIkC(GCje&VLS#sT1w6>yiGPLzHsJAP^wWWaI2X-v!B-(XB;pl=$Nbn{)TKF z^ZEdY?=wx(=ed{Tx%`(BK-oGTr#O*E?#;NX0(@mM#`X0o$e2p6>?t;|NXJ zrno}&I%8-AJ_mSG!tBel`cHr{@$aixJ3Q;=9BWG}Kk(HY|A)#71_D0_z7e;E>V*;<)9%0&{SKPZlb+PlBav_@hKt*OUeJFGE6+UdW-|PMS^`7 z!~EpMf9>^-6Q!I8moMM~+b$@UcrB?rVXLR3b!2lIy2Ki)Q}2ifZ)WlxgZtZ7gSVro zS;T;~@tQG#@ir2ONgcH@O0iqBXu21A*db?!F#`FvNvytPZ~Qz~XGXX+T2TS9vwMpC z^rCsYD!&vR(;ys?hqx=ApPwNNstm=uZ!54;c1xAMm=t#?P1U@UR65GJ+;D^YweZ}u zAO@b!|JClr7n>TxT1FO#F)s5shuU2#$OQBTxT~kTD&pTMEBm}@P4#fzSv@dwO(kc`E~O|F{{2pw1BV}Vf}1Q~0PzH_*XQFwZE7U< z-qPUF&gOmz66&<$yn0T}$p@YetOFx0nr;e+QE^sd6L`mug~bC}wyO`*7_s&+kz!1X z7>~!YjIHN^U>7g*pDH=6$C%kww|XM2W9v_y7+e}F<@}N(wLlba|8N%->tj`GK-Dc> zw6HW-oOMkBOXRRATNQ>=B2R)hh-R!^bs>PzYQ5el*b*K;#pmV(^N(X?T2pwk296w% zX;^_xrsk_!J!Pv2ut~t)=2&r=;uZxHYR!=uEpS)c=R8ZDX_>!al|<^UD0gG zLSd{WUo1UevQ=*;u3lV~yq%5?9*lvc69dEez9zm5L+wzrGKE1j6DC$y?lBd214`8P zAteTCsf$a?gp?a`*!qnbXzV0bPJ;_U6XySd&p;vL&kcTSpyHm z6ke|!FJQ~sF_l7gmcuVZ_Nf@RV>-Q!ndkJAl(tLuR3AdsZ=oLDe=w*m&CggtjLIVF zJ{IKOQlTPPuYrFnR?D(nTKcfX*b))>P(_@C`0K(sT=F~{@zb8O1~W(7?!}92U8bHB z&yoopvWP*6CRhp~Uv;r8KENW?r48CkO&u-IRzVpYU&UzARb%1Z9GF@jqsZh^UKTGe z&bG$i_MoV``am{*@9NfLAMk4j{UG}8>2)td7Ds{6Y@Q~Vd=3e^YE+hY`G~y;F-lcx z?C0Tx3#5xRLF)1KotlSd?X4EyoNbJS{24vphKB&NBnr5+M0{AA89cssUPde~LCKZmEdwEp_BC@*Cd zets0{gy17f)ebe)3@zbKLlm3Pg#%O_bdZ#2gjWhx_;V_9oiOM>(OkbyW-uJ;#7a;u zv;fxz^sEoU+cs9=Fx~!0p-Ph8r}YXO8$J~kqab1m-@ytGN|-5IGjCne9W z5?RvBpB2Danrt?!PT>7TnIE_1e%+P-dQJAjIjJXm#3mK-WQHmnS|a-Ap~Al>ivOM} zeYz<9@{rh;UcSr_g~@HH8zu|=ye+La()=s=PR=R zpDKO3F8lhJ`0aH9xd9vtr&q7-7kYn2^3isod1YJ+r&U#?+uYbL{$!WPfl1t{0kSWT zOP-s{{rrf;qwT_HXK`QNAbM}3z}_CtiZtsLZT$Kw+&7o=&Msu1KeZx1g!9>cv3u(U zF3jf2@nc`s#QR@S@%|>ks|&ej7qF)X%WdoDd%8#D^-=M=>jl=e6ek+@=W^X# zBk**$$h{2$H;mxslW?gxjRlKJN zJ1gVG^GB~-I>|r^Q2fvB=Nc01>=@u`q-Vg)2-K_ilLbf>GU$NJ0Ywu7`=^G&rskH` zwl)SvCMIT<_EuIlb`DN1ZXRCN{z5)}0YM=lL17V5F}`+j2|-CIX=y1*K^a*&`Bnu* zC1n*A)%|;w)YLUJTeP$#_o?pNr=y~)r*F_~Xe21L|JE%jL1PnBvnF#3A?e$`gABHE?IQ6OT|yd zaZ<{JNvbkcu}3_bJcZR;f^1$oII4(fxK+7MG&(Aws1>><#`6Yu_Y|EdzTAhGTHD0+ zP4+c#DyN-U#*~sZ#ju#oSITsj8E4etWxmp8*;~3yML1A{fsp|iB<#!$g^eI_RxVKR zFfy<(2r=*j#hrk`)0CIj+}hmPuBzIW*VES3)HAtIb!u~d^Ylq`=gnWRuux^m(q&5~ mskp6PvsPu%{8^I%0y@<fF6)|@UbE^X-o9hm|>1;RZAB7LP| z6RRX<)=Ermke=Qsv#M8i!%U?^GbE1AlfJ)B=*m|0tGhKHtP_5=iSNM%kw;s^o^KO) zzE9-Ec7a!WMP43|esxsh)k�C#BwYL-E@!&2RT~eqL4h z^+@fI5{m!1{aizWogD*Qjr0td8G#BF z|H(R)X6BSAlxLP?D7bsNDfs4>Wu_{)rzRFD80ncYDE?&Oeav!hWo(=!!m!zf$8c7$8G}c5$c@)mB+j&LX*^=xx--7vghO_>Bg+pA-_mXF%Y}k5KVwo6Ez-q=L^#%flW=5T z&Fmt|Q);I*B#FCAD{D+`EHu#ekWy4%-kYT5DJ-wDVS1977pIKUjs^Ps-YgQb%H1pK z_0=boaY)MUuVv7^rmMr-;?Kx;aeuz%BQ?PiXJbYVQ8{@e8P82eJOzez?5shH9p)#Sf+FR>vEvZ4q2Nbp7ASTcl=2S8tvQhZN@nk-bqa1i z$&*l#1W98}&6=PT*3}J4UlS8slz|Csxt#-dcF$K!4wnBe6gsou9R9f)TVnLb2MP&|$H-GbJOT&&ZL0@P0-ee_Z`!&a-r~Tr|FF&WPVvlR+@lq6q;E)uK z6i^QGg7K|s7i|!BoIFM4T+0`Azx{Z;y`|;nXjFuw?YpL1H}8!4CdZQCbo4%23VRHy z44V2msD0lsmIm)a4D>o_ySQvY)X3OGAs2N2&&N;oXsRft^@7rPd0*G%(KVnF`MvuO z$)uQ0#mono$pjUJn=_VOYCE@60+X66S8=p~rJd4=C7_RkeHz%}@YBI+GDdW3aYuzg z=OATbuU7d_2Abr!y%-NuLF<|EWQ;s`WaDtWrs^9RUT%cr9b8C(M~fq6MPv-KnJcR^ z^^?nSJ^{xf;qG@)mcZV6hPDaE4LJ4|?x|6!U*vRLZRX%JU`h{<`zEdBcPKHe1g&9Q zeb=c-+H1eGZ<+dh4E{1;XgM5e__S!q%NdNv(2ZN3co>5*or#t>RIk?UNl7@}XrbJo z?zUgI2BAbLAH05}LkrIe&?mA##-HGS{!>8loX-PnP`);=p8!i(DU_{hwRYC90f}Bo z-DgZ_O?vI$s)9hjG$Wh%>6E>pQTLJLm*IijE8izaZ(<{SBjzIvqcg<1;tqosD6lk7 z7eqBAgs@`qm=`Bv1R{w&I<~&a9IDi^t(=_^#@wDK6wja4xL6|)D6;fjK``>7TzNY1 zlfSAG^=Ca`!Wf?W>{OXmU#(111!S3o{k3mMnC$)Qteu#%rQ9ghboNB6W&G?PEbQv9 z`5(> literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ninja.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ninja.gif new file mode 100644 index 0000000000000000000000000000000000000000..d422a25552c3d272f9dc23098ace09a92e37c010 GIT binary patch literal 481 zcmV<70UrKGNk%w1VH5xq0M$PL92^|~@+RZs<32t<`r8#wPEI;HI_j+eOiWDw=Oa*1 zQ2**C^UVM$DJfJ`RR8QL@5um1M@QYpv2s1BnSXI)%vN_ literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/no.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/no.gif new file mode 100644 index 0000000000000000000000000000000000000000..242c2f9e41a3cbf41a7185f92ae701fe9a863ae5 GIT binary patch literal 1614 zcmZ?wbhEHb6k!ly_|5%YPfu}*sxTc0Y+&<}X3V<5^I!^Fj|fv92g^jq zS0U>IbFXw9R64}o$Q@SE>Xn>zTgo`9AVOgRL(kU4n_a!uO%Ac*+03_PPA}4r63y+@ z+E-c19Lu1fcP3(YMGm)!z&WNJfeTtMPhoUwFMFuO+PQ|QI%LC#q&6=}ql6bc4Ubxy zmoS%0TsUyZl}FMz=|Do@Y$nF}ETsw=6Pj4N#dN|JNE~Ev>}wWfcX?3o=m;A-vz;G5 z%LQh44%UU@4ILKy_8x3Ngb^bHGlKvFFt|7>fMLY*fuW&Sih=3M48;wJhxpiXIo2!; zIM&_9sNz!MQMmAcG&7IZ7RA6s-cCNo5|x=BQoMRhBG@{97CksQNiY7ILx)lN+4)TI zYZ$yt8ZNdO=0=oAIJ9yD-K{c3@bIw!4kk{9jE4ek-C~+S&pa+n&~Dhk$IOJyG1WlF zgeWjNFi0|Fu@oq7P;6jUS~_Z>waXh)2X>w+1N@<_iulCoJNf ztdY1a=SNVgmy|K}<3Ak}B@(AbRJ#fXwZ${8$&eI4b`K+i5Q88vaIOR0Bhr!l;D8L9Fq1&SL6#m#Ed!AN ziw}<7l4eXNRwO#NwJ@;qW>qu>DlrYd69EZQ>cMd(Y1~|1t3yPxLlo$GDTFQo?0i1x(% z;doe>Nd`x#p(~iX19e`(zsQj^)s+PvLSZ&}qo#!RiL6y_K z^$BP48}R&uSu0V%2K8z}b40xG06Yz_GQ?UPCY$TOa=VAup7I^7=vyrj@(P)$SlTc7 zwGCp|bp>^Ld|~IZWQHEerj#v9*9G$|0Bf!EQt=gXq?2oF12Ij*3e@ zPb|tH7p-tEhaBs`79T)k0WotM0#;ai%4;qsytUAF2EY3?9&oar|NC;m29AO5V)f4d z`rzfln}F~4P6p)v6Bs}pYwT9hFr32| zK#KmNaDRK!`hI^z4DSHO@28+!#}iOtX@-4fv7DP27e>i+*nMf8Zr)|BQY3yVNIzbn z&;hWhxG%M;0g-+~;qy_U0`z@|GV8S}Cr7_mR^52C`)*zWL9F=9kHW4y>f*Roof?ky zUB%l+(EgMt1-b>7Ezk=?2vI(;9Ac+t5vf93o(b`#luT1>z?+kWUP3K*C0|edNTkXH zMN<;7eOE%jlAG&|i9Hc%`*R#nxN>LYSuKwhudFuBczZCi%dBKq>U_h>4bv`b)Fy2w bDLH>(2loT^0F}(yYLunyi#BPp6|mBl7LK?1ytwpDs#2 z*(EZ$E%oa)*(I|Ze%+J5w?UvP({4^FSG=dl>!acq&mT<}GehKeOyIk; zNvt&4tT2N6*&dOF)2fy>@t$2JvV8*I{HYc1&r0o`z?~Pub$zqg`%j;r>=I57l6iko zW@S77-X6}35ZTHM+ch=pSLSoyT+aLUjP%t-JX4B!rgmmbYD;;0N^*6tV74Fo;+eJU zCJLRK!~Ob{)Q#o5*@2wrW^+G3AeJ5^J28*z>(9RoxPjtN7Dfh!G6o%x5>T8lu>Wr; zYie$3ZENASM>vuq`q7q==X8$Zi12zVW~E>@&SAu`x0fYl^WBZVV@ zYpNEPOTdo@0f_=Fy1{xA0ty~9FbRp*E#Powmrx8WP4T#~!I6o>!Z~b*RY+$$hjyyi d5r&tAPcExicZMvHFjQ*o@+fDP=3-&61^^o*6SDvS literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/nuke.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/nuke.gif new file mode 100644 index 0000000000000000000000000000000000000000..a3208b7ad4c355a1cc57503d4f6a58b44e9c222d GIT binary patch literal 1127 zcmZ?wbhEHb6k!ly_|CxKY$EXgnbN*qtNtUFG7}uV0!wx#G%v?)(tW>LkIN zYXo*o;7bpb{ryO(vrO#Ub=mi4rEcz)ytqs5?HTD4^8}VmklfYDnGr0zphvPhmHqhv zv7;*__V#c-*(JQPUu@k(p|__bKiyEs2$nlAiTm#(#rId`%TldMlg-mZg||=Oo82OI zZYJla%d*E-h!sX~*Jg>`+$k|{O2xgyvNx9VuBl<4k;newoRp`fz?ZACH<$BX-z>Iw zxlEQH$LWOv=Vo)CT_v(?qU5~|0uyS*C$*(D=8B#@eRxVS&%`{g(L=s{ZSa zV25*H3n$|xr$e492UwUyRVFB?7L&hYzVeXRLOP4%% zCG##dWcvCd!6-$T!IFu^XU8JW1FFh~Vk-qW9Iwn5^4&4R#6f{|ioc#ofr}Gk;saj$ zXuX;h1_=(W{MGj|3?4IUI8Lmr@L1sBcxaAMtj@zrj-opqo7DTBG#rs^s4)@LV7=2nQy=|r3UP_@*lrj_8vN;B1o0Y_NY*?MlMvzSs;oozEQ7tnddBQsKijC;*6L?{ct7h4s@c?2r)K>AGc)h#2l6;% z?jCpS20CQ!v$u0P%NS*On`i#wjQ@&0sAd#q3ZD-I$PWfjwxIHa;6-atRy@6|f3zR8+2po&DgEPhM1f@-RwWlCsG$EmhP zucv+7>JzA;9P4WEoo@AMJj2H)9UztNFFW%|yV9O^_fT9QqF(&MkcP&iz-IbRw%*^Ca|^#lo6O3Bc*W#iT#j-BTQZDIvlm! zWOlpV_=~RQuQByk_@kJL=Q6YqV;BzLGQzGQ2_QuRNealz16ejmV<9*T$f+Sbu zNqZR|NGPV#U@9FkATTj)>Z@IC0JK#2HU$((ke?0txFrqb#1wduhy$0Ad;M@P(GW!f z!KRHC$KT+BH@r+yiR1rb2``N`Xbx!6OJ!g(CP4h@75!@=fbDe*zPpX;kK^!z3s@mO z5@5&0#J&|8VqdkBze2%d3gKPCM*Imt+^~f3#D*&(EwxK$A(4B6!rx)?*cr(r^u2G+pX7v zC8CPkVvpI|HKXUW9l8DV*z31MmAo@c2@)UUvtw{%zsr9pc1pLM;xBAF9O+H*j4N+A z6k?!U2*eiH{fDZJCP8eX0bTACu_$bT+1|dA?_EloVnAr9@`>x2$O?bh#t`DJ{{NZM|EG#a4j;aI@9xVt@1MVV zd&Wcc`5cBfs~P@3mcQUDb?(fOd|&(WG;0qzk-3w~FI_lw_SDh;PZZy8VpuS}=FF*s zFBdU*$Oz4Bt5{aZQV?hGej`J?r$~yw?8N}tKQ{%_9E|@zQTYEv{`(n*xjl8)uV1-% z{?yeN^23=>+C|36p$b6dE(IOVi0|B`H$U{^Iqalv_0Dt?@2`*w=q z*A=dcG@C0?s+Yr*61>F|yu^yb*&QVX?@wp=dr#u`Ex}KF8Gc{q>dLSLJJv=ly+C zAR|!rN|f5E7N%u6%%`mRznx_Ge2ihGF<-7P`-900_tr7~ez2-zQ2X>gc;w*Jq%~MnKl^l7Y4J(=qlZx$`B*T zQ=DXazL#;LHeZf6`{St$(YgwACs!;~;m!ADj~3_oewyJ>H`CwylAFxbg-inIbQb%R1MDRcIYZa1_*% zWz&##Xl%N~H(O41VRMUPBX97uCmx?49N}bOH?WBa$vn%eo0}vyY4TFOhV2PgWf(Rr zK0QM~J}sg*c{$6S?QBfU4vs2$@>BIKL$(1nqa!5RSG2x8m- literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/question.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/question.gif new file mode 100644 index 0000000000000000000000000000000000000000..81ffe388fda0aabec8aa15bd08239be4f03095eb GIT binary patch literal 1107 zcmZ?wbhEHb6k!ly_|CxKaOFRPbLfNT?**4$G(Gd(?CcMj_+q2{#;qr>*j@T3v*C_k z(L~M)IRi9dDl~g?T?I3ezCdyk73eY(Un(?j(uYAPrGve1w&9)%EW~{aiuC# zx9T2wf9c+Hu>~i1=AF2B_u2HV2MterwmbiG^NGtQr@xsLG;z#1VNu+=bpNTTn-477 zb7Jn!qcgT1y8HAkL*Yb*_H_(}la#hS;ttLbTXl_j`eBPRKNw1;$t9LBOxP*5_>53a zt3b&FhK8l;bM{Wzv|oJnbRi{)nOodr{yc;GmWVACxmomDB%Wb;LkW_1T z<-bqkMBB69<&w&H6Ux;W9MU@Yh9SH_b^3OOxC*J-nG$PmFibfh(=?xV@~$VZJ~4~} z+Ju1OPZmZ7h8_kTknx~A!NBpKL6TF(W5WW+Ch@Qoi-ZRbZKC3QTp|q&N4s6UJ6_Ca zVrOMyWQ*P6@pz#VCzGlcPg4U6Gxr3RV2P?=hfW2{SZ>AyhB5}8!%Xi* zEQ7Y>PIstez-XNJJxL*C6Iz8?%PsR_=IuJoyy ca$<#Z2P@l|gab^9B?s;|a;SL(I51cP05g9^_y7O^ literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ras.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/ras.gif new file mode 100644 index 0000000000000000000000000000000000000000..bae3198bc1b4e51335673236a0c07cdca11d8d2c GIT binary patch literal 1301 zcmZ?wbhEHb6k!lycvi{qf*~ zZ-cv-Kp$V8P-?kbKhMraBepDlwzJId&QpY5?W{r~@;0Rt%h=k{|A33hf2 za5d61U}gj=Q2fcl$-q#_paW72iY5m3{|%K*%`L5MEnJ+6a=g59ikw{SO?*7AG1iuP zI+{s5eC;Aa0j3Nb91MX{QISF-tzzzJ42-O7Y^;n7O2W2&V$GrohAiw%6(=f~*jbom z{1X$JB)ozd%TJytXJQmkHL*8qvPfZJt+;XP1S^9ezlK|rx3etUtCtmQ9L&)^K~21Q zSDdHo%-zQ*KB-6G$g^(CnpZb=9^Pco&!s59By)P%n&?j6+*KS-o01$h_MVt#`uS2z zhm>RLr7b(0H$Rh&-BU8Bve7Ysbyise8*734;TB2BI}IxoUi8gf;NQ&G!O(noDvw?R-y7e!jZ9JKfR)sGdGy?-&3Ws zWYeBZ&gu-CRlP#XTKGPmmpV6#D>Xni$w&O$T<$*)6;>~3nbwi|^T)Su*JU5xy>#=+ z@p~Hup6n9I^5wX^QS9|G@v95DA8i-9xtw=)A-l7Q!2f4T|NsC0byxo16UCQ@#GXF7 z`S$hGAK$-ZhRDyYF-?Dub9ynFN9=PR=NCvrbOB5`B8`1^}8 zlZtpYOcr{1ToP!G;(u;G*N|Xm#{gF&Jp*P&1_lPjpDe6g4E78{{|?MA z@X(R!l$f1rHuH=Q`qy1J^GYO89tzPPRvJEwVPYunT|1vXA;CkDQj(rF7-nU(YzoOrD?xJpYq z)@caHTJSmv*{#{2wx^V9ldOo)c1u>xJtt0RvMv=oY|kq%Dav(n50|KlbO7!^1q zI2s)e$t#(P85k%uF)#|sxVa>3Sa58jmR#He4nZXbUj2k+2^I{>Zj&Vp7Wv$?ROJ8% z2`eZ_*cjLuI2eGT#KwLgII}`%S`)GyD^QLFC?|9v=%u@eSo`t&FI__PW*&K}4>95d z#0WOH5kW6aMCL(^0EajWP&+pR8_)>V1NYZY65``N)^#Z5*Gv)7C6hdB!;DsDnTBfo z^@>ycp`9XicE1AHat4s82%YjkogqSe-G?r{3<)u6KfN?~m5R~K(AGk27uAXGi2@AP E0Pb)65C8xG literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sad.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sad.gif new file mode 100644 index 0000000000000000000000000000000000000000..c9021ad3e40c66ad49fb78e842dbaf1d58d76793 GIT binary patch literal 1099 zcmZ?wbhEHb6k!ly_|Cxa|EbciyYe5;OZ|DM@b9V8zbA^x{xY*BmcKtEdG5lwt2b`m zfAZ?vb=glBrT;!s?5U6ca8Byp;}@@wi9gyd^zx9{&)f2)DOR&5RTd?f967u<(MNJ# z8P~C62cGN_dA3L7=^l~Or%#k5Tf}*aTwTaLv%mD|Zjt+&1n;gFc(h&k!fdYcbla=| z&Ws@WwYBU^n)$CT;#pL~ofas&qK*IAezCnhob#sDy*w^il5BZsiRjvXp-Y>@c6V|1 z=W?B$#l5AMFF%ay=5pQ)Z;mVTxerX@{(MFD#&+>jr;pE^P=8SD z{NVE=5;=bCxd9yeCU7tB59AUeB{eZyp-6o2U-x8 zfDAqc25z8g1_o=GU>TSJB$j-rpfZs521YA}ucC)AYk&3*?117`|DNisuz3`21)LorZGDnlmNZ43;I zAR4HQ>8LnRFH{gHYQ+lU0@-;$1z;)0^!#Z+Hq=;H}3O2 zp%go(Ot(v}{cFUG!w0k;FNs#|SXk(+z$wY3Wns`2lG(b<;f03a490UkY~@9dX4+P( zPZIGv#nJOYfsd7=;@zA*lUa6j3g#@}^AT`9+iuFi!r`Fs@NlP~?wda<87b6_&1n0jJN7x>#A@5~wHycFi++T^+v`1kbo*B$WA8uHN__0}EP)W@lvfcoAa zd}==4un_&?A!Se<|K%e7vKG{z3)iz2YEB5wnF*wrd8L_q)uIe*P6udG9J+}K*ryGdi)m|73Er;| zu8|V$${Cq%2d0{QxR4H~n||4+4Xce2-?9T_${KD|3ayV4dT2XnQXTKn z9ND=T^wk}uf(@E)2mk;7000000000000000000000000000000A^8LW004IYEC2ui z02BZe000O7fOmp}goTEL3J4+`4h|e52nvUS2MumlL0M5NEKUsvhXo8WasZ~L7Hm8W z1%(n@Fb@C$0kgFi2~;f-gA^oC1GcrawE_`9O<;l&=n>#H)VoHZ^6XF!~hTm zDOG}Ma~s0kv;YD+X*GflXXdrD^z;G~TpxmCZQ7>8|GXLKqVJB4Ar+pTB5(?Tv<@-g z2r}|RzyJ>*2xue#!ovUoIjq>3A_&ck9v22IKoKGYiUkjFJt31MgCGhj>Ljp$L6#{D z77}17A%z5mL0^>6h@eHC00;mgh$-PC4lhEYcHl5DVS<4UOp3T*b*K`N6l;(OSrW#~ Xr%87X5@|RwV#Emzk>Khz6bJx2Kd&DE literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shifty.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shifty.gif new file mode 100644 index 0000000000000000000000000000000000000000..2c4cd98730b1c5435cf4016826962da948145a31 GIT binary patch literal 901 zcmZ?wbhEHb6k!lycvj8eY$6cvDU##Ip5e`r>C2JiE14C*nH#{76U>z#!kHh&l^P(M z79f)zESDLgkQu5_6mM9ZXk40XR-R^6k!D?yZc~+MU!CR9nZn+m%QY*XeNqw6>;m@L zh3xanxMtM}EUMvNTg$$rnSWUm?}|45=+SoJC%Z(R?iP8v zN94&Kv1fZkp6wTVenjHsA+gs-#a|y2e|cQ;%}L4kXC&X9k$Qho=EFIukLRU6U6lTO zMfU48*>Bfnf83V)d0YP1UHLx`75+X_{P#rh-&3XkK=e#$>Fmbk^I9&PJ96>-(MuPO zU%7Ph%H>m6ubjDl?fi}F7jE3Rc=zs&Cr=;0`}pbor_b*{efj$HFAy=n0FbTtpWDwh zB-q(8z|~04fSC~}rTCMDHHD#?K?kG^6ip25{~D^Bnp;}iS}F^(#aUU!vI;8Oo63wh zR9z#(t(Dk}%GyhWwLB)6-HCV}sTCN}DV6bdpjtGEZb? zq$b4#DCm|q<#ENO96xy?BPAi!kv+G`P%SZy;Wo9FFAuIQMcsumnXlcC&&1h zh&FMrxpI1%ul#;#ZU!$+cY~QT%e=Ex?gTe-%*f{5Uh2H4sYyXXWrxV&X+1MH%ge@b zWKCA^nr`rF6XOF@mUafSrgvK;3{y`}H+a3x$MaCL^A^WasRad2tlZ*y5vwc&4=J-S zC$v0sIl>=Ba_dJk8YRl>~Cda z1P2rsD4CS*y7>mZiGB&`7gm|Xk- literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shutup.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/shutup.gif new file mode 100644 index 0000000000000000000000000000000000000000..7f8427c5bd818058224603824f1a7a9df9839992 GIT binary patch literal 19930 zcmeI4X;f2Z8h~#?$PQ#<3jq^$F-8bf16oPKj(|aJi&ZgU6KGJNjzy$48;ckL1vP|L z6R?7HDd2`nTNV*eL_t)nTSUR7Rt4IQc&zpYl-i@yGwKXF%*~IS{K@%}d-6W-^DZ|5 zLH-<15e1+C{{(8Sa=R?8blEIO*q`c6{s zw^8r5Qtz}_-fFV!+HYRJ#kBoo$XSBG^&A7I&a3|EbGo|?2b-3>faGRE4OEYl! zN!TTGFo^<;cs6$P`m|D2hIZqMvf`EHn-n`gN0lU_N>WhjC8$HWm{l>TBmp`h6umHr z;^RSx3bl+CSTCAwlQ4&#@Buw_q1&e-_kToB{w&TbEpBSsqG{;~-YXKh>oTJYvtqRy z(!VZ|io;OxGte=?#&H7L;Hmw08+YG5Qmsr)`1!#0^V`0xTrDkLk=j%F^~G?8K0zN%`246srQMdw(C%7=bIkSCu0zWp()c^(_$rwZ!ZUE!}Q-8cZOi<{@01873 ztkm#iFq&|=dz`Yw69uPH0yW1d7FN?TgjGJlrf?LlViiLKha<=?OCuP*p;8&LEk{+r zRjQDaoqPjfN0d@2yt}5Rl8a~X{ntk71l^b~Vem!xD#3vBtnE?G!pgo_1$V+EM`zc> z-OLV*Win^2U1ca5!CAY(VYS2n>zIUC2ZL>_yI5^>yEKsR|1Gi#Pnr<614uG<$VBZ; z;PFDV$0JD>#@oliv#9=E=%O;Yk9K-`|D6L$q(F;tNE2&qlYJ?sk<8VD@+K3Y%_4)M z_2KIP4sRBvn|!n1inr@?T6_Oejg;-pGS9V*%e`wi_pbXR`v-KRA}daas+L!VB2J2@ z({`Yb1{FF49!%agkkYLI*z>FWEkrv~GV!Frav=`}(_cmm0LcEljM;C6H4tcC1P%DR z9%haH7Y;o}>k5DvF&x3j{1iL?5UXK~NOFtJL5xIb?XY@`Y>__0h=6FX$4D!P5eZDL z#|XEtOpg)Wo|?+qt>Go+oTB9ZI0@I1&+MF*UIa#cq(6E`ca#kNO@LEOO}l*_cQS*Z zn0sgg?807J7*k}Ij0bsAciER<-l954J$yS>!)4~#e_>c9;xSq^O$)?lEh%wuB-QUM zT3IM>pif_Z|K{?H-jf=P!?O5d+hjx$WdSX_@6&P<;Fv`^p%|oxWC~Y+|Iy%PRS9?N z3X7JGr5YG}x{Zm9A12{ppni4WzRpTaaDqt-F>G9xe4A~)|Mywr3Db)aO zJ1SrX{%h7-kj^`ez#|5N2V^Ou6`Sw;Id23HddQH2JO>YYtA;n^AoVRJFnBC_*g-_j z!iuZ0idq-eh=VNlSY=l*;vfyH9K?vcXAZK7%l^|rCg#~^4p9WJJ-&c+j`18t3>bQf z9LVT30Ucz7BFtfmv^_@=0!WeS67DXLBA|nS6k(C|6j=;XMDHNO82Q%}iO?b~gcTyc zzc@$?koKp8Wc`hUfW^*#ywVxAkKr2U?+ctO)x_Z%=lKE$tZqiFw0YIKW~8VYu4rDg zjF*-(sK=5tnOu>XrGVkX7tNm^_X!G?EklHbOt7R`J5QbwhR8OIViJgGG?8rOG&RaF z6S#k4B1SVJ$swF z_YuuK0up7h@3o+*4t}w+1vY5hz28Z=fnfA4nTd}AfhDzO=mC z6hl(otXh8@t{fMG*w!A6YAfNG)^)ba-Rg6!=BUxwl+123uO+=eS57cQeIMDfh8iUrlr4 z+vluzNtzy7Pu3U~xqZAxDed5QTyDsOL)HwH=kI(b8s!i8Mu~4UtQoJ>Tl0(g4z%XK zNY>XcFX7J#tT#Xj{KWELgy&9e3(5g{J0Yip6)uMdB>0&~9`L8P1beO<8;SdU6!TN*c|ri4_(y=OUJ_Rn~21Ft0RZ zn}#$?>{^68afCo;l~vHg%J_+Z^(kwnN>fskbu)5i+DuDlZXWcB&)zT|9>5K9J2<1q zb>-b(V3ozqG!h(j7{*@#*S;@d9>N^)I(}M;Y$n_g788nGXDz-k7<3<|cAC7{Mdg|j zjm&2(XybAs`eu+FgY%Nl^KV@9<-wvN!VQp0>IApIrB@_|hKQ#PyOsZ*EdTe018?52 zd+AKzH3kB2cNzdjBq+-(pUSfFoW#h;gvCR$96ocBmCd*bUSZ*&EXTT%$Y?a#)Y`>6 z7L?^ETQUZZH`+%gI=?RhWm!DY9JlZ2K69GGj86x<7Er!w{`oB&@?B%g}-{F9dF`FIW&LZA+JFu+sXREHm=I_ z#!PdnPa8V1P%hu;op$?F6*;AKllRmeT%t#55H^1}Gv z>^O)aMCV$v=C_8dVg&8F!j}&9=P^)k2%2Dx(UkQXUkl1|ua@N?dO-AejW8RdZ+Rnn z{6BY=ZJ+_wyEvc%!xWlsk3Os32qQ1{>FCN6Wg=Fx^VRDo04ZA$QPEOc5xSk?I#O!W zccw4pKP$CiVbvcc+3KE^+L^2O)LkS89@U*8{8k}CVq3cdZ6gR)W|Vro`eI|;S3HrU zP!k@rrk3N$!FLy;@;9|CdW=^KqMnx8?S82i-k&`LYL!~lT2Fg~ahd_5QS-jU@epRq z!R)onFcg)3ExMoXEZWjFS=QJ#Q)Y6CHSJj$gTIxEtgp*msCErcRU9|-8s~(?5*l); zuEVpbTZ=|U+=kDu8NHqT7-$#orMq|#MBWNPP#B6uEo{S-=%Y2opVDhu4{m)xb_*h_e8G5pWPKI z94&a7)SatSGR)%G^x#4lL;U3Lm4x`7Muee%x!G3*uxzp?{DOijoGt!9jpk^C9sYDn zg7^|OiD2$WVlR6yV`8vM3a|Do0&F_B8XCGOY*%O#vI|rgi$n{NogmNHSn=>?%Wfw& zm8)V))K?#q)C~*CN|yxGx~nG!Wbhp&>@0&IWslQOAy-MQhae>v+mfVoDk<+ z)%ZR6F$Yc$T$OtW7PEA&A~l&tJ@;WkSSm*tWIaX8c7@~Ubqh_68 zCBiIT6YzAy4kF0Ay3Gp__^jx}bwZfezA#Xal6~StAb8^?=RStOwiu zLk@zZg0yzjokkJpmF>xZ;Nrn0#P#*@ z$mm09h#-)Iyo!SuL7h~nlREm5`mUY`IS4e189V>10y)U&a|Ut{XchwzWc1^1?3@TW K$g4TX)IR{u%|cKB literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sick.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sick.gif new file mode 100644 index 0000000000000000000000000000000000000000..f0bd582ec0aab4ca16dbf59bf1161f6278a6e630 GIT binary patch literal 703 zcmV;w0zmyoNk%w1VH5xq0OorDBSR3F^%RZi6951Imh=>U+YV#E2!GrT-00$Zq<6*F z$nEp=Xv7K1+s=;b5jS-%)8W`2WE6nj4{*#1>+(&4UX&*T(|~*r+sO~3V^77d)N&eVi6>08FbJKb_CTSWpg$6r#Gk&IfYQ_pnp9)g01V)?&Q;ZQXh5;RD z2YI7*Hi!j7n*$nV1{q`pd!%?-wFW+t2WFOHaLo%RYaGMY#z1>GM3@O&w+3m#40+ZK zDSQJXZwFqw2SS>PNE7OV-s7p28QAhJCg!o zxD0%yc_nEXz|_M{p$hEt^GT!wL3}zVY8!mm4n&>-X~qg3YX(Q60vKZjTDJyCr2;R1 z1{!4sLzD_al?Y$B3O#u>ecKL$-w$}z4)yu{000000000000000A^8LW004UcEC2ui z02BZe000O7fO~?2goTEL3koM75fLCK3JZsV2njPePIymtbv_9QhYb&Oc>)d&0v82a zH4hDi5NTlo7#0Ks78n8&6In?RgA^@X0vQAW0LjS$1#CbuW`ZG6Ulqpy0|VIF8!T`_ zN`gdX0vgEK+UNi%1|2tocU2?T+RE4f2Mj@If)Q%-0g%~C<{;l06@t3xDHpI|Lk$Ah zxk0$ch87vt0s?3Vph7niR+b3*!K6U3W5|$YV1`472Qh-kv~eMUmMs800PI52gvyW* zf+!p@GNHf)0RT{405Cxc2PiEl41zIchlv#;4jd4%!h{zNJ!k+UBuY*Z0}L1#Ac1Ag l3s;96D$VIIv`WdZmuVa6}=}yp-TFXJt$HhpH`tcZR~zF z{pdLq(xPA)`ZGP;5A;G&%!$#IhF;W=W$gGgZm!7;TnEoJ{;5V{)rEO};m4>jz)rB&}?pQ0>Hn#CH}{M7TB@QNdf4Af~Wq| zPXKQd$W)o>ihZaBI2@%;*$lwtN~Au(x(hx!{9dxi?yO>GykIgF_nPgvx$j+_#cuhS zdqnE-sjFLCh&|Ku4HlWD+js8*ZPl)oftK|`Ng-uN;U0p>)BI-ji+RHziZc7 z%4@}63wH)T%l@HIk(Uv)$Zyss_HFr38;B`)&#pZ*q zob!)5SOV;9ZvI#2WGz-+-7@cV;o;=7Zvi*ca%N)acu;4RO3F$qx=z~fosfTUJaA0- z$?1%=cO*&KQAok^N{@Y7d&tGXGtvecCJZ@8ZF-fm!SXvMC)F?M(=_ojtzv~(0Q>&| D^Yx4i literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sly.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/sly.gif new file mode 100644 index 0000000000000000000000000000000000000000..307ae5dcf2597b4ef36dc0b7e9efd1fb5af23596 GIT binary patch literal 500 zcmV|Nk%w1VH5xq0M!5h=bHe{%fqjT1L*7ScV#-Pb_4$69rMEg@3H{et^%Es zcj~JE_R0WYOBeXf0x~NDYfS}1I0Kz`1pnn8T}u%S3jvXYWc=9?|K=m@#sK}^7?)=R z_RRtQ;2O+@0(oo?`_~Q5i~?s-9sAl5pqG55YXkh-6!5nIa#aV{*VFR70N|AXZcqop zi~{@E58d9~a9%Ld(8~JL2><3F>7oGt4P@#V3>}Tjp=yazLjx89Aa*`JJv}}hE^7rAQa=GG4jKlC zJvBUvA2J6EECE6agdLbXn>`c;7Yqm`BtirU7ng}P7&8wOJtk`*1VRl5wKx?x4<8W| zIK3PvD7&detVV-jp6hXrhDrc?{8szG=<^$ zY=#$$8Q!dBc)y9^!*+&Gdl^0-X83lR@yA)FUzgZ_U+4XOga7vp!9Ow|Nlhc|5L^P&y<$VYWV*jXyGUr4FTGQfZ|UUMg|5x1|5(!pgh6A@q2LL52@O0MU3SG;f9k&v*CLzpS;42RB)4-fcj zPNr!%-q?`LFZ#r4gVmyq4-QUeElE&Fe9$PM!ep)YCXxASqmfk03Y(|~c0QgyJrf7U zmX1B^EKOdV4s>kiS8%BLa3QgoX^N(*Kte(zb2}FgM~UA~gM$r>oX5O)I2fz}%lD`% literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/smile.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/smile.gif new file mode 100644 index 0000000000000000000000000000000000000000..fc0cdadfb0a553af8cdf6f97f30ca49f5dcb52b3 GIT binary patch literal 1125 zcmeH`Yfn-E9Ebns0>{)8_2ey3j&$8x+1AC<8dTHFE~IU>wMwzfveITL-93cHG$)u& zYnEol>}J_q<*E%Ys|3`hZe*pPqIU6?S(wN<)pzJ+&jM74^!<< zc9Yw_NOIB$EJeu=h8gvBL-$~`8p?{!-Yhz2fA3*4!qF|nktm`y7n%M*CT}4gDzQQt zZm2*9wP4IaADqXorQl!gfT2lOeHj~j228J@y9#l9^zP82rYiJdHePxT|6T{_62;FlIl!68))%gHnER65dw`_i3Ez z;n(M&<{Bh9hL~uC@2_B@9+~~B`3|IXz*7marhVFv)2xhqgHwxsF zt=tJCSDp|y{lV+lRw6N4FmM&@oxD$9N7zBp^(%6wM=&z}=d}O)GXvBw905?nqQ8rO zn*b*ks2Ti?kIEzp*MJw&xH?6)kGn6QROuweqHwEfVOwS%h7(?k#L<;B%9(dx9nu~z zQ7C*p`xC_#&bU)x$Y!yor`gjL6R8s0E!me4%$f8JmZ6*#^0&dB&&u5>w+Mu+eeALQlZ>B1K8^7P%^ z*ze34Wl$ZWn0)=>A(Dk-?(y>W*B#=w5_o4k=DZZ}&Kdv!0Hc|Hbz?U5)*YU93gx^M zUr7|$*wOOQ8`00j)Y8f1x)fqf8RfeacV;@FmU`>P7uBH)Y)%JnRtlSO2Wn6Ww2cnb z)5_<>7_gHP-meg%d<&Xy2Wd?R&8ifwj}onY2cMOA=D!x2eh{aM5ouK*a$hmuvJu#~ z7ru}S(y|uo#TW1L^VQVMrJI4!n+j%79H*XyyNU^OVKdOq#MPnHw-awv3Er^~ zq=OG=O9-Zd4e7@j^VA)BX+Pw=7TK&2n{WrtoeS8f4eZGo@6jA>Pzbh<4(`kv-LDX+ zh7a4W5TTcQiDUTzCZqco`K| za2Oqh3OjLl0|Ed50t0v+2rO(0gFE1VmkmJ{5FoI?#0D@YY#0GXXiX9|S0s!WA;FFoI%IgHIaFze hh9659+8~h;<o4e1Kr-;a9%Ld z(8^#+7V`4)v7-#2lmmlw5`=gFo|YG0SqLU4GI(eJ`qK#J&ky&|1hcZR|K%b73Lku1&bUua|H8cc!79So`KMN;1Acj4c z02MJHI5Q(83qllx1U{EMnH4rL2saQ0B|;4f2c@T(HXRiJdlg(LU56A3OvHd<6y+LXrVxAOIf- zF+vE?aV`ZYA%ZsS!;u4qAqyrC{Q4U i2o^1lR3Tv?!Gi}043PLT!V%5y{HF;IvtN9>jU9ew_Q&kvt-K5+@Ld!s~b zV1tbY2X`~wFPMvP&+-1!_Y4pAul@pdgSYz$*YU`2ae0MG3bOTsdv=R^CiGg>IlIBf zrUU2n=6Ul|_iXs&)THEir2Fv}_Y>agZBSnMbnQ1V7)G3vK_4ctUB+NlKDMF;moemA z_CEU~W>F6R+bb9B4}EQV_^0=Umg^X2Z;X)6sZIBF-BvxmK7e1Xkj$&VH529-3p$hW z#<5u6%9701&(QTDMtdP@(ZaeOmRBrNNkWa{)V1oO`Faq)=W+WyV!aF2duUfV;+hTb zFF~|&r2b;yg9n3+xtON2EhCP+S%O}_eBRmvYdxTAL^ehlhBhQWjTluSMcMqN8{nMc zs4LLte?m?wXQ2TsUErRN$W0qT&7U_nBSSB z#NVB;@*^bkV6hd%AMC6w&Tvg{*7s`-hT%F1rY=XD&!V4XzUdhEUsOX&)0fvTU@lXL zu20ikh_%SDQ)yxALqxThKGjCE+=JR&tnfs%b0W}b413xE)5htWrC8O)Y!M$U-7xVr zEi)x#pn|qB>h*CNF@1|BeIGAK#a)lX#K}ZXBC)XaY^fET69H6Wpv%OWy9!-p$npFPt)^Kh-Ygy_3--=R_00b}k;RKb%{9MM$`zR`= zSC!0&rDc)U=4wr}m|F0ns&^cLci(O*;4;Z?P+q$adnYr7WTs-~jv9@Yt_ECFK}r1s zWu87iHz~VR(m(bbRT`^vs$x=w;Ux`H=mr{vc@5tBPWaVYTf=ME;{HEtZ( z7JNdXG_$077QSu&v6FlX?{-$WSUK_G6fWNLOqrY-xrD4h<9-xT-5qm6D1B24#-?_%fx$!KX1mkt-gBtjZmZ zO0gb)DOf7ER92#3Gh}gAq>9C9fgy(~B?6LDi(w}QMr;BO1{*^GgP>SvL=q$jG6~Ws zmKaQ|NCX1G|C-Z(>T3WRp#LcFs1s=Vn{CJ~=9iY2>JsTpCY`8T$+yj2>+3jq>GoXP z+u8@?$>#OeWXG9Fy>_YQk#LWrrVZ?hhc)?AF1So-Y}s}?V7Eiv5(R6N>9EzuhqmOf$p9d}<*mrOJYS1rS{Oo@V$ij_s?|oa@ za8mii^f`vP56gY2u}|}TYPNM1oxeL%c%d#VpBS-V;Mhc=`E1YN9rP|c*_a%B`FvoE zs<^wC&wKLK_0`VdkNKT(Z|!|&|N4e{`NQkv)Jm7VlS!?->6zJ=t0~&PHu%iG(*5PP HPGIC8t*qHs literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue.gif new file mode 100644 index 0000000000000000000000000000000000000000..fe77df2fa24ae94cf63e5a621eab152b2f79ec49 GIT binary patch literal 698 zcmV;r0!95tNk%w1VH5xq0OouE@y{Ci-5>ttBL3td{NW(^+aG069o^m7qL_T|^7Q`# z0O`UOZBPiCa0h8s zAmX*V57*YusD=;k(Hz^Z5YU?nwvP_fp9`g%fuEIllZIv4rwwOQ9;Si~ zW>6f7WCzvM%)pWhX;dI;PzmYB8RWbc=D!xxuoc3j6}yTFZ&nJLZwJk)6ry|!r=Em+ zYCzJm7IR@U-LDYX*U+$&5}R=c-?9P_4)k(0000000000A^8LW004XdEC2ui z02BZe000O7fP8|3goTEL2~uETARul^Y6*ve3SP1OoyB0|a>v3vE;fgLF)01s8h9d&hbO03u%x5P~UOaRhpM*x40&77a!` zB!X~wc>~$!djokV5*i$W5i0=#=-C1R03lNmf(BOe^|0N`C&NHL72s+2>6 g9UMs)wsdjvX%e3VA5fSWF~S6j50dN(E))m=JD~L_)Bpeg literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue2.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/tongue2.gif new file mode 100644 index 0000000000000000000000000000000000000000..a40cc914d48d37526d99a7ee3ec7e21147a33b2d GIT binary patch literal 1099 zcmchW|4ZX_9LJxZ?KNHAqTSo=7{{kFl{(VoA}u31W)tU$saeVWActSZG0aS5sXu%; zKW?UGoNSkvT{|%wVl^%=;nqe^9H|@LTkazTQuRcbySn%Qdww@yzP`;r|4C3Tr8ewrPL49 zRBZ^~p!AmLAERh2;qRr?cjUe5NN?zZV-&s@?r5OsG zyTOTJTSqNPm&(F(1d$DEctq?11czPUAxvl0Y2mtA>=~d1ruHkzmWaFG zDm5v8@c*4B{w4v)L*a4c@lHU?VbzLN3p3@;BC3D(aCby_`h|SaVD|+*TJ!1RUr**( zG+%(+sZ{J&sVm(%`sOmBe0hlJ)Fa#aKPs~1Ps_(u{gIUw z5-pT9dNXMMAm^1E7d39VYE)Fwx67pYNvJ;YjhRiovG&myzhq}n;_aIYI~GGxP5yR;AmF9{0BFK| AzW@LL literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/unsure.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/unsure.gif new file mode 100644 index 0000000000000000000000000000000000000000..c79d65f38260483c0f47c7b9f643ec737b733676 GIT binary patch literal 699 zcmV;s0z~~sNk%w1VH5xq0Oof9_}d=w&l>*aBKg}N`rRMb*3Y1pdDPO$;GQ* zG4IS7-QC#f!WRGKBL3td@ACBZ)*WF?7xK{??(y>c;UML_6!6X(WnZJIK9gAfLlyeN`ycC*m2Ww6T@AC8Q${E+Q7TBi^-?9*8SkPCTeJ*9#T@6jBohYxXB3z2RLl7?i?n+vUv5}}rQu8|Vdp9|!= z6RV98|K=h?G!Xy)|MmI(000000000000000000000000000000A^8LW004IYEC2ui z02BZe000O7fOmp}goTEL5C;NV1mwkl2mKNzd;q{)n}K(V zc-c_Ffx>e5W!TPR2Le6F~Nfbg+UB@xUe8%L4W`YL|9N^VuzJqghZ{GfdB&r1R=fEOEQp+hGlwK^HqX?o`S9~xNRZ+6~!=6Rm^zSAA;$By^bP!0XA zCPY5|<>ModEbmb)77hO!S$yEc6M`rZF_93dKZZboDF_9m<`oXaOf1AoY<^J!36ltk zk{J3(11XaVsgeRYkTIE%p#W5X0tIbI%_n$p2oi#ZU_KBTb6^Rqfz9WmC>%tBXb^Kc zxT_pgf@)9$JG2JlU=lFMFcN$L2D;z}La1RdumKG$G@DED93jlgY_1Grk%_P1UZrMasP0c>TzX?h#)BeQX^oz%D2WRVsDklm%8nUxhRhPTdT~TH^8hx)5F zYRg}f(Z1T9{i}<^pSGUOadYEQ?HoNn-(6TO-yfT58ORj+rk^%N71K{1cFtTMojSR` zbbDp(=jQh38>J8F$%U@D!5go~SGMW1i8F6X$+=(OQ`z3ch5Ei^!$2x&ay~yGmhI0mwKL=Wr_V1Bi7lK~ zb#4y#%{2nusq8m*O59m5u%?E6Qd`RVGm_~+vNQA8XXUeJgvjQHa9%ifq%_%V{?v+< z?fiKmT-P^?W%zI`o>_ZyIq%*c&L_J>wol+IOR+dGiF;lp_tix_uTM$6Jta9YkL&$e zsa>6%=|M6VXLFrhB~qDTn;9a%wqNMdh2yJx1(&t*zda-U^R|3;AZLQNSVfxkx!K%> z5!_eib1$4;J*AlE$u8k+KlY_fyifOt?3lp!_2*v(s)8>|(}ik682nh2n! zLRB(fHf#hrV?z*78CW}`6+?0WLrgwHQ4vFWE<>UlgF+5NW-&vmBSXv=(7NyGwuRukOJnr z>=Hos53dzM)u7-Ks`UW*cWML3zcrr}f3g5or7`G$w1M&j1IK@cvm7SO3m!N$vNFop ztSESRsEzNeibjEBGc&uCo`{D);DRP*+f_XYi&(m*>adHrm^dgTHnRx`H7O<}C^ktm zFuhqSf!xi ztA-Ukha@_cE*zZ7Vav@otNfJ%8xj0YRrY6AA&9I0v>xz1V1XLx_7ebq%3eyY;Nu4W@cir1^@;+Y^MMK literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/wacko.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/wacko.gif new file mode 100644 index 0000000000000000000000000000000000000000..c293c4c8f36270d6e0e976555aca358a524713cc GIT binary patch literal 946 zcmZ?wbhEHb6k!lycvj8u>#qFA^HTqwDE@n@^yi_%`%hm|17zQyk-U5N#{Z{Ei)PgP zyeEoA&#J*mWefROxqwPYIT9dzBm#s**`EX9^?<2)e7o}ex6Mwo#&#Gv*GI)~t`WGsPT=~r^O?RJmp6#cpIVXQ$9`kG_~f?KCC&Wl z!E$?hIExdFKVOl}597Kpo2xp@AuE9M>?)Dv^IFc%;$GV?bm_wJEAzQ8Z4%22QCQK& ze{~U0PB7Qf*^TGsa^GDqkRQVNXuI%%N!-htc(?WQZI~={V>$1${bKJweV$#&zPpQa zR-M4T^#W^a*^A;0a|1XooICPlk64B`$IIiAS1zCWaa->HGbLvef&c&ifBpHF0SPGn z=k{|A33hf2a5d61U}gkLDgI<(Wnidg&;cm}MH2)2|Ay+O=9bpB7FMg!AUQeH_%hb^ zCLXRh%P4K*5bt0vo_1;3T#IrBhH^fUVq011Rt^WVauz0LW+s+$F&A=9a&`e#l_p_N2Ik{8UotSN zr3g2%m3}@sK~uWnJc|VL--;=R4{uO(W_*1t!f{7>lOQLHkVVRj1_yIV-#QMZgQ^Z2 zSx$UVS#dz8x!=^CrB`6`u|sohwiU=deyYYLWZ5L=qH(#Qi8+|z(~7JGP0U;w%>o97 z&59=)85sFu4hXazo-KTU<8HwrCk_??1%)>bkCj+ul-lLAL^T-~dyARrzNneCWqAV! zue?*sj|Gk`D*HOPS(y+)#>T+Lz|O!73^HC|kTq3SHMdt)wpTYIRIme8u!2=^165R3 zHMLb$wjs%L0Ogs%^6U*&l}#*_CTPjeeAEKCi-QC#a<>T+n z8D&r%{o*0-^7QG#7Vh!#^3fZTg=6;D9re~7@Xi|Iw-W2d7kFnp<-8Q;ycA+h8DB{h zqnUoyp$m0mHrUwFp_Y2l&&B1t6x7nmo^}d%W;*1$6vCtxq=OHVatz(C5WbKLy^IOc z(8p;_2-&O<&Y20`uMo724x4ZXp_hBDeFv?N5|3>Pr=En~un^|I7SNjt=foI$YCxxo z5$nYl*{2Q7nhV>m5Yw;~ntl+wiV4o03+cxhnr{bhR0)%YW$*IyiDU=Bk_)zv4%gPt zn{fxyvKFFz3(cw&@6jCC*U)lbG32}!?8zBvR3O;57i>-k)uIg0&ctm{2&J2WY*Pwm zP#kz>JEnpSXHy>T%o^Xa5pPxsu#*ycX+Pev5NTB))zr-M)E%gX57?&-)YHn;p9^S9 z2;#RBYETKEm3VVuGea~G_}d=;<|6g^{Qv*}000000000000000A^8LW004RbEC2ui z02BZe000O7fO>+1goTEL4Qx0)8X9R|a1Doo2?t<4QDsmWqM{GaY6`8-#$26AV8T5Fnty0tOWwYJ>qssEVB%FDi%-Q6a}07)-1@IaJ97 hi4|NJ;uJw5=hGxT4MuP%v0+0A4kIMp9b70706V^J92Ecn literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yawn.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yawn.gif new file mode 100644 index 0000000000000000000000000000000000000000..a8d5fc49508a3eb6e9cd5578a62d8812d1e11580 GIT binary patch literal 296 zcmZ?wbhEHb6k!lyIKsfd!ot+m$krssv~Qcz$u6esAaQ#${)-n*F3e^9`%tDhk1x_& zXi{tPrIk$nf=tU*nLh4jQjlYP`ut_78PnP}76V_5MOS zO5CaWArh>ORxPdVvZc-WQj+ybx&3h&MN0kx)6xYb+p?oX=2X{k&X?p!Qub#NnB%cQ oQc^t2PmDuy!{!Cv*{Y_j94rzNEF5+bYMR=*`i91rj1?KI0fByCXaE2J literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yes.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/smileys/yes.gif new file mode 100644 index 0000000000000000000000000000000000000000..f728c3ac87680dd71d397c0839cbc63f8f6cd310 GIT binary patch literal 1307 zcmZ?wbhEHb6k!ly_|5=`~BNxqV~L7b@pvY8E_%wfqTPb zp-HXD^QTrUoL04HM$Lgq+-GNTU7E{ve7VTgh1@rm^WI)3aA~9HolQcIwhKMkE%N+` z#LL5CFON&UJ1zPCqRfYLQr~aN{(GvpY);dKb4M;+IDX~w=^NKC+_-V^?%f+to<4r} z@$>)x|G~~5B}PMl{18z5&+X?L671|4;A*62z|06VN%1EOt1yt(0htQQCJY?k85lWa zJT@#i*kqAqp%JjakynPDv&~?FB5RMhssRs&U|@R_mtk6mh-Pyu3#%2^JBNTIw%+Lm z=|>6{G9Kh>lC#>;aj;MDwHVAT_tjii%WsUC}87c zx1ja-$<7VAUtJdy1wDy{aF~gZ&PKTpytO156W_;Y5&LF0) zRwIycn4x<@>r}P`ucQOPjdBJ%BxDwBPG6>`#v;2Th?!g5Amv2E!zNZPVR61YDl?oJ zSwytMHbg9ZbfklwQ$dc$v4M$QSk25uVS?!*2N^{%4uK5{Ed|eSaI>)>!h(f?g@KoW z8yFT=z_8#^5MVgi#KAA+a$-ZGvlOeM)fA3~M-J_*{8}jz4sJ(VW$f#C95yZSXcP;y zTXJxcDuXD45(`%2EP=)?QA9HCFayH4$M%MxiINsU$^2v(}jG>8i@TEwl0)(hRQkRytVUwT;2}A`21q>9bgJo$)J1Tv_c4%k%vp;+9uRC+j_kH)A z^DSHcPEc?>12BLFfF~1Ex2$b7<=Oj_#T!?-rzgGrby=ph>$+{|VP(mIZ86lEe3#Di z%&|6)$F1%+Pco{roRbwuceiCv!jhv0u_qSx(|ex3_j&z#oAXP%hpmpO+ez!|>rPtZ z-B9iJe8Bsqjr($lH({AO+Q7W{nNw1%_mhdqL+Z_jL-c3&yj~1)r-yjc!@ThhkKsB- z1 zJUwlzsQdC9+qVp(4&AKajJCM9e}(?k#2UQpdh;mSWpKNH4*UL7ByCIR3AJ-ijbm9V zbnHl4N-Q$`BlG@Q%v?s@773Z#n~tj-ADnl&rANzlKwD!xFKL~I>KKoj=k%S$PJaw- zQLwx3n0Li5(r%~roWh2_W861j-8GKwrAXc;Xy*rkcW!qit%83jLT^>ltjEyr@{yw{ zP~y9=wX?OV^x#KZLOxi|nBKm1nh4g4;gneFsY3d#3(V`aZZ$bh$&ql`Cs^rjbe#kq zZDf91h@L5?m+wPU1i>t`z7Y`EfXzs3$f)E*NT=c^s|Jc(j|}x+`g^5tTkj zzVLwXdc(*n+LDti&+&!zin4$-1M3FANmCtm5XOR(7R}N4mTQiwda?&ElJvQ7CpWwI z$2E^Ci@U;=5MTO&==9jA(b0)$K=H|^XL~%}&!b_2{^bSej-k6NxeesQ0x@ZLL?R=N zV4{uuzW1B29|7X1P3{(A7P;AfSz-^Jtj^11uSg3|sLF(09JgILabDI|a?Et2)Oq5l9==&!*y9ZJ47|6d<*tAazy(k`mgQ+wx(%_OqvmnY8Q?IVEj^W z;aFgw+#{$6LRGM<{{~Z4yhH^-Y8DHd1(R_oG6QzAgXIdH(GHfT6)77v4i3bBLwezU z*tmHW#w;8eV5-tLs&rFw>jkLNxRm8g`Nt>}0O9ok>^U=v!n@wi*$`Kxkz|TyID_Q{ z#8+*QndxV3U;L--uP7#izEOkmS9~cyS1D7ANMo&nqN)hb^oXB(Mv7X>4|%?Eazl^M z+deNLfPl+D00cnCFMucPh2rK%m8(b;f3{rgLZvu)0IGFe=Q?jCEMb#p~YMU+f za3YL4O6exPtwG_bELIJr>YFiM4)x7n)=dctzT9ky3+xsrufLoUGZni!x5JC(-&8nc zk^6Pcqd0sc4@}#^cadB&5AbU{U>D`DkCUoPg)zSQq+w(+Z*sW(vy1ZM0R}VIUo>U9 z-J9FW3}m_u=f&ocu2Z#NMgSdY=qeL2TG=?kEW$ zI-!Z3DCuN`B74KO4M-kl$Ra{R{NjB^#lc9~ygiDG(oA2XB-_TVeJ6^CE*i7_OkBb6 z4rWA;n${@SFIY>gYva}Ch?k~Q3NaR0jc9%At{CbQwDF#c$%TP_MH2T#Z>cNvgOURA zlI^{_rNDO6IcUADt=MP8>0u!t_SPSo?_3@V1v$~++5eG&BOWjZ+~&F94Y{s*S%-Kz z&nLeBTn$&7?JzeNvly=#GiLD=JnXL`$p;dAJN}AfkU}e2y5FZ3C-StYF2K;87{2;% zI?gVN7uW}H3RieLt6)SOSAuaH)!eWXLiu<@PM({L^tbrWa+vmBas|D>zFaE>2Bjp6 KG#B5L&_4iqRf0JH literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/bold.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/bold.gif new file mode 100644 index 0000000000000000000000000000000000000000..4ec8e727eca2a73c1389bf8a1e9db75c860952c8 GIT binary patch literal 76 zcmZ?wbhEHb6k!lyXkcLQ^Yi=v|G(l-7FH1kMg|=QAOOiQFe&%+uRQ&he=*CJOA)?x d)w}Bo!!($rZZ@P9_ogS+-n?@U5%f cT~`>U!6bFFA+2)V%MPzkKG(nXiZECM0FIj*9{>OV literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorback.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorback.gif new file mode 100644 index 0000000000000000000000000000000000000000..fa177eeca03336f4bd74e917de4583146df01046 GIT binary patch literal 138 zcmZ?wbhEHb6k!lySj52a|NsA%mX_-3Y6dVHNJ4<(PZm}Y1{MY#5ErDDf!W_<*PVX` zlMJ7%zOrr3)>Q`tLZl>wm|Wvn7<`-rxJ}N^h~L2R`>o!hR=3FhbsgNp*tEkz&a>#+j`j&Fg!z7aOAYYn`M_Q! Q78-7)*51)6BFJD30D)#dpa1{> literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore.gif new file mode 100644 index 0000000000000000000000000000000000000000..053ab65857216da6a83bd81299369ba87363d2d5 GIT binary patch literal 114 zcmV-&0FD1gNk%w1VH5xq0FeLygoK29dwT!?0RR90A^8La6aWJNEC2ui02BZe0006* zoR6u?Di32D;ygR6xqBk+C17Y(!HJ^G6&$VcI_3ems|f(7t}8)QGXw`QM(pSbv5;Ty6mXJ0%b)wEzGB literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colorfore_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..61e0fb1ed745f768f8cc6c8b8b08df1f7a0d3094 GIT binary patch literal 174 zcmZ?wbhEHb6k!ly*v!E2|33(~w6s)LS2MIQFjO=A2a5qk89*{15*aA|WMLIy;9}4L z34+XEV2KVm>A8CEjb&%6!%lALjMwOW?!GYV=(Z$_GbX*ghZpiY+TSs{>v)0tkDf(i z!nT+wHd)35Ee!##<7X1MBw{!t&p24-afL9qR3&7z>ob`;T`=1-|LI1#WAA@!3Nly& E0QPe`fB*mh literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colors.png b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/colors.png new file mode 100644 index 0000000000000000000000000000000000000000..f4ee2e9ff8c4b26e4782ba40957fe578120b28d1 GIT binary patch literal 1286 zcmYLJ4Qx|Y6uz0kn1wmk?QIcBv<_ms4Q9QlWfDR68aA?(^#>8uA#7eWDyEZY1$8Kq zytY`9Z3M0~t3Cq*B_&;^ZlW_WeNpFCGDV`%Eb)ctj2KdXvicLQ-+fVclfLG>bIy0Z z?>jdy(G^@*QNFmG5K__JribxAh+ofDSKxW#UQkL%Ohz6vTc;g&O2qT0OA_$QL z5v7DOLOG#=P^prP62=JQgbBi=s^ye$MmQ&25H3}#phPetI1z#f2_zyZk&H-Aq#zOj zumKG$G^1LoIqEPN=%00U{TL@9V+Ft7m)EUBDRX~Z~!bE%AkK8!^q1Q!y% zLM~V!$)(^DKEi1j0A47E(NGI3;Rk4<8+L#b1VbTM0}Q0m30mNR!N3NzR4Y=|NF&CP z*cgn2K8!^qocp1Cb@r{2&I*;y&Q?^dW3+PJ@lLfmcBmyd3Kfz=TJ6N)p@1D|TnB6k z=0OuiO@4a*3EWKDuHPArXMX-{?sD6LC40Y{+tIlB#nA?M>3*&E(tC4vbMKzVr^HNs z@BW+X_vrdHPYwS1bhDjVGkI29eWABKjgfbmK3nGV_&q>$~3a#M}C| zkY1x%daU@CT{Gf8wrlF;3%{j3?)AyAeSdM-vwX@JH8Y;(nY!zY%D{q9DC#<-jrc9^ zvB>$QBMs*3rM77Gmw}2<q9eL($8tX>(5TFU0L%I0RJuA5a^lKS8CY=GbbK$ zZ%LlD>dZr>@L26*`n}V^u}v8a9|~?B%(NJ3b8xol9V2HRon5ip7&Z^jF8|Y*G_$kK zR~pYJBN=<>bMGSqUtI6IXJJ*Vb(8PD1B>b{k8jI?svgVl>+V>zHF4UyZN5qAVP}5bMeVP`bFsBCK!#f$ z?CfjtT%E{T+hY0>?R}%i9{0P0$%s8x+L)=@VXZ12oj3f9zj=j`vIoYSa>km%##ray z-dyTh`}p{>ovGXH-2a8UHhf!GS=eg78ee+3_MlZ=JQ!~nPV`&-_C(y>o!s=FnC|T8 a5B=i||hFyFj%sC39Xz7O(3hnHDRt_C$rg$vjyb6`Bv67Ytm&#>H+RAYmajk$Kew=Q}(+ zElQspR0Ss7XvNh>=ryi=fG?57V|Na<#TxvK2hVQ79J}YNt=GHG8cm=3+r?SCMJGnPNqzigEOK705XqM}KjiG3e$Y7F?K%kIRhTKD=RzQf*YJHC=olPi^kVSxd zD1bOgUvV5VPyhe_A^8La6aXIpEC2ui02BZe000HD;3tk`X`X2M5s0EBg*qaMVI0n+ z5GukPgTT+RX`~2^1uzg8OfH)Q3NdjUZiWY>lEI)95X)l0ct{|cOy>*1SS%CBHls!* zI>OBMkr^1qhq~0sCHd-jVm*BbE1d(kr#;x9(gKI5+t(e+f{vH2@jyAw~cI literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/indent_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/indent_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..58ba3e5681879ffb98cd823e472a449fe7529101 GIT binary patch literal 90 zcmZ?wbhEHb6k!lyn8?78HuJx)ukZi={}~t<6o0a?iZC!S=m6P3SrG;XChaNxD^K@6 tTqLs4sr&Vu2dS$W=6-B!@5p=Zk;;2J>6O~_TX(JqoSXcYzXYh-8UQGGA$b4* literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info.gif new file mode 100644 index 0000000000000000000000000000000000000000..3eb3d8970625a853af9e5f754a2f2dea0dd5c2c1 GIT binary patch literal 651 zcmV;60(AXHNk%w1VH5xq0OkMy|NsA3SXkcP-n_T5nVFe0RBd;Xri7og|NsB$>gsK6 zZElL7%F@=!)!mu2!$56}y2sM|{QPimaL&%oFfcHkuDZ(Hz|-AjpuJd_x`wUB5M7QEOm+74_2S^(kBNksvc8D2$Rv294P1|I zhMDZ_>h$pJ=iu4Cwy!#6g^H`ZP>-+^YMGq9(u}go4qlK9M|4_ph11Z?^X=pA=iI!m zmuQixIDMiGV3JyEc+AMa^XuH~;?yltW-f1*4O)zgt;G#gh7L}92QN^BiHgd^y7A`J z?BB|~tB@EcFTl^++~n)9!O>KBmk2ObI!jokpqSRpzV6`4?AyY;sEQLGD+o1R2|H#6 zGhPNKOe!%sqMVezwW#OY#_Zg|yrzXFCME(35(5+^O-)R^w5I9Sx#!WayrX}kp`Wm- zpvbdr@4vkD3X06Td1Gs*w} literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/info_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..3eb3d8970625a853af9e5f754a2f2dea0dd5c2c1 GIT binary patch literal 651 zcmV;60(AXHNk%w1VH5xq0OkMy|NsA3SXkcP-n_T5nVFe0RBd;Xri7og|NsB$>gsK6 zZElL7%F@=!)!mu2!$56}y2sM|{QPimaL&%oFfcHkuDZ(Hz|-AjpuJd_x`wUB5M7QEOm+74_2S^(kBNksvc8D2$Rv294P1|I zhMDZ_>h$pJ=iu4Cwy!#6g^H`ZP>-+^YMGq9(u}go4qlK9M|4_ph11Z?^X=pA=iI!m zmuQixIDMiGV3JyEc+AMa^XuH~;?yltW-f1*4O)zgt;G#gh7L}92QN^BiHgd^y7A`J z?BB|~tB@EcFTl^++~n)9!O>KBmk2ObI!jokpqSRpzV6`4?AyY;sEQLGD+o1R2|H#6 zGhPNKOe!%sqMVezwW#OY#_Zg|yrzXFCME(35(5+^O-)R^w5I9Sx#!WayrX}kp`Wm- zpvbdr@4vkD3X06Td1Gs*w} literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/inserthorizontalrule.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/inserthorizontalrule.gif new file mode 100644 index 0000000000000000000000000000000000000000..a2320e19694904c556d23a49f91b692a1c7562cf GIT binary patch literal 1007 zcmcJO?N3{E6vw|8ieC1Bmmh5hOJ7`OjD&|~FB&tI7{FTCM7%CHyn>_`+jZSqxR&c6 z=4RY-!Lg;mGWUWIBHPl%J zC;6O{bH3-C-ovg#uS#Z^@r1zfieu*Ene^SXv&Xsh$5!lW%roNI_+g{`cR6t@p@fv> zrRDyC{>*oo;-AIUFITfaXVs6?N|h-xAL&2RA2<=H{98$<(y_}iaZv1hqcd_YlKCd% zbUBOp;_9{4?2p;X(@NrYLOG=@f3_?h6*um0l>aK<`0B>iuUqPAH82`T1kXQ|rid>M zZ#8(p39|%7K~{3)@I7fY!45uzZ3)o{sDN9f=%owYROKn{pw#dprJpa{!hz-90k&@lx*4YB&P zk>$g>7x0w8r(gg~SjZr9Ocg zVjy=#Xru#z)(fMV$qr_YM~?uEwFsenlR~V9gd;#;XF1@3fw>1>PeIYigdrH?3IQj9 zUX(&e$$*%3y;cMW#*LQjXIp&{yT4C9W(5C>HUDEWu7RL^r~1xMfX(0~*4DRnF{!il zm)Rs2)*IL!o{t{5lYD{Yb3hhmYUY}4++%JUbLKsD=hyi47tejdRJC*6 z_cy0GzDqvNyW?kf?;EKbYJS}P{I2~DA$QQ-b>{Q^?7R>?c!{Y#^0n0_brq9!@9fjW zdiR?@)msJwhvL(hhD|TqCS|Vbi)3xHpxun3rk3p9HFWQUtj~U0$2mLeFJM+@Y(rdW j^Uieb#fhgKH-9mi8ulJ-_?_?4-nzc_{m}m;}4IP-VLfkrZ{@ij=HmTc}wH zEH#Il_G)W61{LRANu|h9I=L2cL9AR;C#l#HXjg8sX4lassXxfgGWVg`C;KDz@ci)p z;o*6|-VZzn-)nU?_tv5oPdV&u@=6o&^qq9zXh@yY^6O?~IPUvEQ08@GlXzQw(nKOO zAZm9^Etxhq%=|MFpH8IL@{R+((1}Q5F(r;^+Op2I`o&>MnO2m!ROFnZXNkEaahi;6L~^SuNnL?(c2YpxP8KL$=fC*=2Oy`s;?9MPm-9|A|ndl z7B{y@d`3%Uh%_P_8N<=! z9iNB?j)f9)T4+$=KNi$QJ-Rd|v zPBF5CbMxLqel=-CMr8Sds;?P=FGP+4pOB1olHVZOis5bZlP#K5OJ_&{z*z=6fjX*a z*?=6tqEtsVV`n*_pGSp^sAKltV^p!DC5YgMD02I7vW`l;zgqrB7AIM_S`Y?0MiG95 z?lLfTd*CoIiXe|iGTjJ=56BjGF96C_{Idsa3@^d?m?A*wDbC_B8o?l2-)QbdG=>N@ z2v#8bmz`x{7O3JW0#fkVvqw9si5a?t`CDZn4<&*p3_+aCU2 z>K1bL7|Zksctb#Y3=}-%%r-q?+gS@%z|b?${(4u?`Y`*1W7&RCFq&N{nH7cv!51r{ zOfno(^i?e2(I~6cl;GNbkq%Pzzg5HEr4)nyLD8}J6R_UJSJvm>y)t<{X05UGzOw2W zb9lns(B~I_X{mf+siVOrc+Tu7tGmPmSGQGv>p8APnIB86`^u|!KX}mNDSi3H^Nl}6 zqw$u8kESMPCkMqdWtB&rL(NyDg{F=LU+3-2%^ejxyVM2u*=?u9?H@`V%;xXsYd)>M zX6t*^g|{l+Ub^M#jh?sd^hQNv+tg(xlg=VUTYt))qk0}QTf`Ds*J7Aa=LPt yjg2nd?mcZ-?EcQ7;6TYY_0QQ}cV2pUy@q+`liZ~H24g?9y?*MqTl+tAVgJAA?v5`2 literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist.gif new file mode 100644 index 0000000000000000000000000000000000000000..7e7acbc781ae1afeea84f7a4706d8009cdf28383 GIT binary patch literal 84 zcmZ?wbhEHb6k!lyn8?5|bLLE6U*G@#|1&T!DE?$&6=7gv&;hc6vLXx&OsZ4*SDt>$ odyna2OZUeqU15AiAu~d5?wr`Pd>h;9x^%T;^Shr1F)~;K05xkJ9smFU literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/insertorderedlist_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..a7a1c0a8e60ad4657effd804c6ef3f5f910db815 GIT binary patch literal 84 zcmZ?wbhEHb6k!lyn8?78HuJx)ukZi={}~t<6o0a?iZC!S=m6P3SrG;XCe$ m^C(zwMnmzkqF?+{p&C6+ZAD@ywr6Zwj!~U+mhI4tys3}Tdy%IgEasM9viFx literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic.gif new file mode 100644 index 0000000000000000000000000000000000000000..8fd547ef8e8f24e03e32becb1bf4e0677ed33c13 GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?7ebm>w*KfnL~|1&T!DE?$&6=7gv&;hc6vLXx&ObS!_SDt>$ izu0BrHBGGp50cJS3R{#iPGg;&68VDr_$MAw25SJ9t{E=? literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/italic_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..c781bda7687bc11eca974df38b7aec1a312ec7d7 GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?78HuHbl%rpQ0|7T!eQ2fclD#F0TpaWzBWknbmm=vb;uRQ&h if3eGgYnoXH9wwcw6t*a3n8r9eCGrLL@lQOW4AubFc^X;( literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter.gif new file mode 100644 index 0000000000000000000000000000000000000000..6f1c340b6e85f9aecb00dd1ea9f586c93db4172d GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?78mX>C0Z2bTKe+C8y#h)y!A`DCnIzTp1R)m3pNnuL=%F}Q8 ig*i4~vR*83KI literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifycenter_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..ef75d139ef6b046b102e3433aa05ffe05149c32c GIT binary patch literal 70 zcmZ?wbhEHb6k!lyXkcJSoB1CI6o0a?iZC!T=r8~QNQQw)wx@sP>9_pCGqzmoXx?i1 Wj=w~}qLcsROx{)7-f@dFSOWm?R2Lfn literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull.gif new file mode 100644 index 0000000000000000000000000000000000000000..11b2af6b16192182c664e6f2beba3a3ebce380ad GIT binary patch literal 80 zcmZ?wbhEHb6k!lyn8?78mX>C0Z2bTKe+C8y#h)yU3=B*RIzTp1Rs_gaoYKGY^jm&m ij?I^>lefsQ^Oinhw@MD5b#I2*^6SSw`N*>}SOWk{T^H~G literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyfull_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..1e06876f887ec406a9516d7eacfcd24ff6310c4b GIT binary patch literal 71 zcmZ?wbhEHb6k!lyXkcJSoB1CI6o0ZXGB7YQ=r8~QNQQw)uBU(H>9_pCGqzllSi4N( X-Cf)HVpfYo&7M!)_KsVcmBAVS3kny` literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft.gif new file mode 100644 index 0000000000000000000000000000000000000000..f2e6142c4e0009ed808c30389cc5b43eac78300e GIT binary patch literal 80 zcmZ?wbhEHb6k!lyn8?78mX>C0Z2bTKe+C8y#h)y!A`DCnIzTp1R)m3pNpVX5%F}Q8 jg*i4~vQFM&^FqI55xZG(n3KBOvQw{)ee#iJWv~VSShg4@ literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyleft_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..5f88cce51833d3b7738ac55c98d9bd19d30e78c4 GIT binary patch literal 71 zcmZ?wbhEHb6k!lyXkcJSoB1CI6o0a?iZC!T=r8~QNQQw)uBU(H>9_pCGqzllSbNmw X1%C;jMWH_GFSru|0@=v literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright.gif new file mode 100644 index 0000000000000000000000000000000000000000..5df6220a3a4974701c628c68f473acf56aa3bf4b GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?78mX>C0Z2bTKe+C8y#h)y!A`DCnIzTp1R)m3pNnuL=%F}Q8 ig*i4~vR-Vrt^IGsBX+msFe7!hW#?WU`=lezU=09LJ{a`? literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/justifyright_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..854475517d4edf9112f830baf2012cda14d7fcae GIT binary patch literal 70 zcmZ?wbhEHb6k!lyXkcJSoB1CI6o0a?iZC!T=r8~QNQQw)wx@sP>9_pCGqzmo=->MD WEq{rGMJMmcnQ|+)y?ZUjU=08R8W`IE literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent.gif new file mode 100644 index 0000000000000000000000000000000000000000..9ff7c2f40b6fcaee31ae716f015c51563d8c5099 GIT binary patch literal 90 zcmZ?wbhEHb6k!lyn8?5|bLLE6U*G@#|1&T!DE?$&6=7gv&;hc6vLXx&OxjcWSDx;D txJYE7Q}^pR4^n3{-2K?t-jUb#BJpfS&8uhAZr!;eaPIhD{t}>SYXCSsBMSfk literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/outdent_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..18e7ea0ae6bc43b25ce8126221002699f3c6b5b3 GIT binary patch literal 90 zcmZ?wbhEHb6k!lyn8?78HuJx)ukZi={}~t<6o0a?iZC!S=m6P3SrG;XChaNxD^K@6 tTqLs4sr&Vu2dT3e?tW}+@5pO=k$5(v=GC)lx9(gKICuOne+f{vH2_A)BR&8C literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture.gif new file mode 100644 index 0000000000000000000000000000000000000000..431853833c80d01151f1544f3f2fea17d07f9f5a GIT binary patch literal 622 zcmZ?wbhEHb6k!lyc*el+|Ns9tZ{9qA{`}dqXAd4cxPSlt-Me>h-n@C^#*J&&u3fx% z@#M*qhYug#w{PE`J$rWU+_`=G_RX6&Z``fIw1Fg z;)H?ybc1_Sb4zPmdq&PqShCPv zhHL$X4Fd84>(|I|aB%Ax^Y7fhe>)4G2?K*8FRz9yC(F6*?AphU*=ZirU}a+3uFA}O zjM?lc1Dg~hvt3B%#$k7*HeN+ds}6y})lO~v zU!xAJXiRPwXi>~d{9y3tNSC-t-isHCOFRS>wp;WVEIic8BW+p1pqR8oZMBR=@vA#0 OwI-gQ-@(MlU=09qr_5Ra literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/picture_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..9b2fcb34b449631bc0a135c56b955a9480c9677b GIT binary patch literal 625 zcmZ?wbhEHb6k!lyc*el+|NsBnZ~r}e`Q+k@eac1$`;~uY%dAvI6G4<5HB`2;fId)^$(Z$_I|IIpdqx0~;jeC}@*}7=; zmWAs!ty;5T<o3&{2+<9|m&R#TicK`I5(gb-(-rLjP+1J|I-rdwz-`3pQ($d!4($dgU*VNSB*wk3xR8wEm zQdwJ3SyNqJT~=0ET3l9KP+X8-Sd>?gpI4BVlb@59SCEmJk(!p4lA0PHpAZ`x9~~7N z78V&293B)H9^fDB?-%Un6XNR==<5^Y;}xLq)$if%8KxFoeCT+oG z%a`*r@Gn~&rOmx@(C;ZG$ z7_%@l@6=^tI>F@TdV*D%k#XmPHxGhXS*7*mxpwO4yk*kyw~$e=vMNfv(BLoME$_DE zipD}G*L6H{9(PVZZ04Ax8nons!^G9i9U=xfUnGiLJcTtQHn^M=ebmA&Y26^Q$>&tyr;Q!GZ-dX3Us8dGdq_6S}&(IyyR+ZIgh81>2V^$LPYi6i2PPJH z=t%XSSW1ttN5AOO#X(3?=5f4Ve1}6zAIR!-}PeHNZ5GO`qf%(p&!i-Ct#M)LW^Rceo KxXIU%!5RQi&1=a3 literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/redo_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/redo_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..a713be153519575117abd82a0fd55e3119443b0b GIT binary patch literal 339 zcmZ?wbhEHb6k!lyxXQqAp8O<)G8}@2sb*j8ptc_s(3KTH92YPo0?l#ddg}sggCP( aN-uI&RbpK3q^Y#VNt}DbmaV>y4AuY$5t#G< literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/smileys.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/smileys.gif new file mode 100644 index 0000000000000000000000000000000000000000..c8ff3e41cf6a7d8e7c9d0b8d0af915780fdab325 GIT binary patch literal 1106 zcmZ?wbhEHb6k!ly_|5>1u1nZ6uJzLHr1oVfuUIl)}{A)NVPTxkI^ zsR6R-!E%`)3PtgT#fiqH$!6tgRuyU173nrrnf7jOZq->1Nl8haDeV2ZT(k1oCl&F` zE?}Qm#x<)>U{MYC+FJHyO}tB*`B${@FYgju+b^`Gmv37?-|jBXy*-@!CU9?!aeYkBPrLF8Su9d_63&*cqI(g;tsjFAcT)%ey#`Oy~Zd|;3 z_r{Z_kKcX#^#0T5_n*FigLae{>>;4|lZBCi;Xi{8$f2M-!NBpK;XkL0$A$%tO+{BG z985US&}x|ZL`LLCnj4d_%POCTj*kxXn6uyZU`R~$o~{?YB_{EbqtooBJh?YF9?E}hKx)KXQh{&7F9LX;>b}rns@22*I%uJ7ZWxJ zZ|<19ZRw;ZZjb9l+cE;BEPcYY+`<9`Bo-eL)nk086x&sGlAqszWmez?mebQ1%nGX< z|GIeeF{ZK{Dl~j_QdGBcGJ8eQlJ@o$%y%t3HnMO{)ec|b5~;MLorBGRbCZ7O21X7c xRj&yWKNFpqTTI!t#eN(()Xpa=!%;Kmhd-Z`lrV?F0Tz=5ih}hVVj=>1u1nZ6uJzLHr1oVfuUIl)}{A)NVPTxkI^ zsR6R-!E%`)3PtgT#fiqH$!6tgRuyU173nrrnf7jOZq->1Nl8haDeV2ZT(k1oCl&F` zE?}Qm#x<)>U{MYC+FJHyO}tB*`B${@FYgju+b^`Gmv37?-|jBXy*-@!CU9?!aeYkBPrLF8Su9d_63&*cqI(g;tsjFAcT)%ey#`Oy~Zd|;3 z_r{Z_kKcX#^#0T5_n*FigLae{>>;4|lZBCi;Xi{8$f2M-!NBpK;XkL0$A$%tO+{BG z985US&}x|ZL`LLCnj4d_%POCTj*kxXn6uyZU`R~$o~{?YB_{EbqtooBJh?YF9?E}hKx)KXQh{&7F9LX;>b}rns@22*I%uJ7ZWxJ zZ|<19ZRw;ZZjb9l+cE;BEPcYY+`<9`Bo-eL)nk086x&sGlAqszWmez?mebQ1%nGX< z|GIeeF{ZK{Dl~j_QdGBcGJ8eQlJ@o$%y%t3HnMO{)ec|b5~;MLorBGRbCZ7O21X7c xRj&yWKNFpqTTI!t#eN(()Xpa=!%;Kmhd-Z`lrV?F0Tz=5ih}hVVj=C0Z2bTKe+C8y#h)y!A`DCnIzTp1R)m3pNoPv`%F}Q8 tWjTTyB7EyaVl8T&1R`ZUmL^7Ry5ZQ#SD7PZdy04Gw150OT#~E|)&M=L8DRhb literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/strikethrough_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/strikethrough_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..e876a85a2fb60b97d8b9a961fafebd052ddfa4a9 GIT binary patch literal 80 zcmZ?wbhEHb6k!lyXkcJSoB1CI6o0a?iZC!T=r8~QNQQw)y{CWW>9_o{GZaEB{EuBP g*%>)ewCRdxZ|0S?=flks&xAbhc>e30F)M>L00K`Pi2wiq literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/subscript.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/subscript.gif new file mode 100644 index 0000000000000000000000000000000000000000..39f4c421b574a7b7b3830ea573ab67b7c0e17687 GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?5|bLLD228RFt{{u%WQO3;`aQi>B?1(!cWbTmHp! gG+C0DpPlmhZ=yIufJf${DZ3^;<37GAn1R6>0Baf$+A^!Io7~4g{SjlZ1^_;87(M_1 literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/superscript_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/superscript_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..14f20209d542939fd9558b51581255cc7a82525e GIT binary patch literal 79 zcmZ?wbhEHb6k!lyn8?78HuFCN1H=FSAX4!s3#$kN6N3(r4U`pOU|>?1(!cWbTmHoi f4y&?w&&>`NXK~ADO(~nU%&O}q_wi4E#2BmrO2`;- literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/table.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/table.gif new file mode 100644 index 0000000000000000000000000000000000000000..72c52baf74563d37f2cbc00e70b6419ec6884d48 GIT binary patch literal 1022 zcmcJO|7%-S7>7SMy^R^BTRbLN3srBY8zpT+#0bj-O-e~uEp0Zgb>J$!C0UGX)|f;$ z;WBT&v{oo1DMd;NHmvE0Gs@5+LxUtW3~@!!b^f4XiVl`0nKB6uZSZ*dNBI8m!hz>K z?|Yte&ft*quualKkNX6?ijPO*rHxYNV&?X*w+H$Mw!Yt5|73k}VX^UN>e0%&24jv@mgzUpi2zPvlOhZ1y zS~MVX1_=ma$-C4dabRJB-K@!m(e4E#*rE1|Fbn}s#(#)D2ZRvBmh-I2i-HGmuR^fF z4=SCb-n-O8r~v8&^{vn;g?eO617WtU9p(;0*a#n1Pr(KqV5|cbkB*!-u54s#)oO&0 z7gSe&!{rDJ$~?wUJ9dHC=d%9SmpMZWkV63t?yi6+-K(@>qXZP7RvxIX6d-43Tsu7@ zBo>1#3$SmaBLU+C){;^ z4RfxKn-kFQ0;ap|!D>gC7@5CGU~2bfAOItCH$CoJI7ZGgVVpAvoCXH58iXwXh-K#y zCW|1%Ml!!^^3I!mM+2wW;(v^;zj^i`2zqyW?EVR8e!@Xb=g}+aVodY!p^{E0sAgK9 zX%CJr z1QIu**P{V>^+tknY3YK(m|;#?#j5EUzDM7hX=pIjw5)njAoBbb}u{@yK^wkv+Nt)>j4Yt+ab>-|$j8 pQH;#CrrH(?mdUTwx+_n)1;-bk+BL1g+O3avF8=XzYl{lc{0BO)oRl&oNM zL_v>pGsp4dsvwhU>0X4Xh+Wac9CC=o!gvw&;JEQG@DJ$6$B*y9ySxux{Y-6ku9*Wl z&;cV^mgTqzF2D-Ju^=LJ*5Me*7UC50Cy+D9dr10NaI7en0;v!yiHT1LWt4Ho80`td zH0fy?J20##7#A#vDOn&n7d(iA=0Y-IcxbrPf)f!?@szE;c^>s&MB!_#s1QkQn7rM&uZWEuIkdp$R4&n$wy)0vxLV{8?)r-!}Ci)!@%sw>s$ qznI6QBTL>^`rGWxhtF$LlG~oHSj4Enusqt+tm*0ZbKlDu8LRO{Zz`&sRlZ91;fr&u}$Og)aFfcG_OzB^F`Yr!r p9+QqNd0Xjkvojw)uSrR6d%9u~qXNV7Xiu}Ir{B+gFK1-11^~rjA0Ge! literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo.gif new file mode 100644 index 0000000000000000000000000000000000000000..fe9afebe51e0d32597bdd03097415f3b64a39cea GIT binary patch literal 333 zcmZ?wbhEHb6k!lyxXQqAJ=+iELgB$#*7)0Cr_R*VM13|S4T%jb8~Y;LqkPH zMQLeiK|w)oZf-_KMnXbDL`1~@|Nj|i1{8m?u!=A!GU$M80Qrf5E$hI90uLRj{u4`z zPR1|^u`w@@w9-(BIHIspKxm!#S+=Gba?&mODvLKJSWI9s5~^Hd+9a^RIZ;7XsIUQR|*yhR`_gh5mw#92UShA*R#$Xq8O(PfIPe5=;24{>C$1_0Zc BXA1xT literal 0 HcmV?d00001 diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo_on.gif b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/images/wysiwyg/undo_on.gif new file mode 100644 index 0000000000000000000000000000000000000000..8885006e6b660830752c853bd51779fa2758b331 GIT binary patch literal 334 zcmZ?wbhEHb6k!lyxXQqA_|n@$m)>kT_I~a059cg+s?0dC%|C_~o-Y?tz zZpp5f6a>tD?T)=_|UcNM!|v)1v4I`PkEm(;X}fN2LT-)0vdqm zL3quDh?+g_HTMInw+2*PaHx3TP;kMa;DABF1BZ+Q4jCIP(>6IIEU=7QY>=?QAYy?* zzyt-43IG59XCNIY{$yblVbEjH0ci#KiGeNKVS0gwj#U4NB}FG=m?U_Z7rgYc(7EBN zC@CnkPU-T=OEctDn-7+zys8NhW7$-+FyaQ2xWdy$1w*M)wMr+|S`TTJ#%AX>eh*z8 oZ7o%$Ua_= 0; i--) + selection.getRangeAt(i).deleteContents(); + selection.getRangeAt(0).insertNode(tag); + selection.removeAllRanges(); + WysiwygRangeInfo[wysiwyg].setStartAfter(tag); + WysiwygRangeInfo[wysiwyg].setEndAfter(tag); + selection.addRange(WysiwygRangeInfo[wysiwyg]); + } +} + + +// ***** InsHyperlink ********************************************************** + +function WysiwygInsHyperlink(wysiwyg) +{ + if ('' == document.getElementById(wysiwyg+'_hyperlink_text' ).value) return; + if ('' == document.getElementById(wysiwyg+'_hyperlink_url' ).value) return; + + var text = document.getElementById(wysiwyg+'_hyperlink_text' ).value; + var url = document.getElementById(wysiwyg+'_hyperlink_url' ).value; + var title = document.getElementById(wysiwyg+'_hyperlink_title').value; + + document.getElementById(wysiwyg+'_hyperlink_main' ).style.display = 'none'; + document.getElementById(wysiwyg+'_hyperlink_text' ).value = ''; + document.getElementById(wysiwyg+'_hyperlink_url' ).value = ''; + document.getElementById(wysiwyg+'_hyperlink_title').value = ''; + + var tag = FrameDocument(wysiwyg).createElement('a'); + tag.innerHTML = text; + tag.href = url; + tag.title = title; + WysiwygIns(wysiwyg, tag); +} + + +// ***** InsPicture ************************************************************ + +function WysiwygInsPicture(wysiwyg) +{ + if ('' == document.getElementById(wysiwyg+'_picture_url' ).value) return; + + var url = document.getElementById(wysiwyg+'_picture_url' ).value; + var alt = document.getElementById(wysiwyg+'_picture_alt' ).value; + var width = document.getElementById(wysiwyg+'_picture_width' ).value; + var height = document.getElementById(wysiwyg+'_picture_height' ).value; + + document.getElementById(wysiwyg+'_picture_main' ).style.display = 'none'; + document.getElementById(wysiwyg+'_picture_url' ).value = ''; + document.getElementById(wysiwyg+'_picture_alt' ).value = ''; + document.getElementById(wysiwyg+'_picture_width' ).value = ''; + document.getElementById(wysiwyg+'_picture_height' ).value = ''; + + var tag = FrameDocument(wysiwyg).createElement('img'); + tag.src = url; + tag.alt = alt; + if (width) tag.width = width; + if (height) tag.height = height; + WysiwygIns(wysiwyg, tag); +} + + +// ***** InsTable ************************************************************** + +function WysiwygInsTable(wysiwyg) +{ + if ('' == document.getElementById(wysiwyg+'_table_rows' ).value) return; + if ('' == document.getElementById(wysiwyg+'_table_cols' ).value) return; + + var rows = document.getElementById(wysiwyg+'_table_rows' ).value; + var cols = document.getElementById(wysiwyg+'_table_cols' ).value; + var border = document.getElementById(wysiwyg+'_table_border' ).value; + + document.getElementById(wysiwyg+'_table_main' ).style.display = 'none'; + + var tag = FrameDocument(wysiwyg).createElement('table'); tag.border = border; + for (var i = 0; i < rows; i++) { var trN = FrameDocument(wysiwyg).createElement('tr' ); tag.appendChild(trN); + for (var j = 0; j < cols; j++) { var tdN = FrameDocument(wysiwyg).createElement('td' ); trN.appendChild(tdN); tdN.innerHTML = 'Item'+' '+i+':'+j; } } + WysiwygIns(wysiwyg, tag); +} + + +// ***** InsSmiley ************************************************************* + +function WysiwygInsSmiley(wysiwyg, url) +{ + var tag = FrameDocument(wysiwyg).createElement('img'); + tag.src = url; + tag.alt = ''; + tag.width = 20; + tag.height = 20; + WysiwygIns(wysiwyg, tag); +} + + +// ***** UploadAsHyperlink ***************************************************** + +function WysiwygUploadAsHyperlink(wysiwyg, url) +{ + document.getElementById(wysiwyg+'_hyperlink_text' ).value = ''; + document.getElementById(wysiwyg+'_hyperlink_url' ).value = url; + document.getElementById(wysiwyg+'_hyperlink_title').value = ''; + PopupShow(wysiwyg+'_hyperlink', + 'tag-bottom', 0, 3, wysiwyg+'_hyperlink'); +} + + +// ***** UploadAsPicture ******************************************************* + +function WysiwygUploadAsPicture(wysiwyg, url) +{ + document.getElementById(wysiwyg+'_picture_url' ).value = url; + document.getElementById(wysiwyg+'_picture_alt' ).value = ''; + document.getElementById(wysiwyg+'_picture_width' ).value = ''; + document.getElementById(wysiwyg+'_picture_height' ).value = ''; + PopupShow(wysiwyg+'_picture', + 'tag-bottom', 0, 3, wysiwyg+'_picture'); +} \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/.htaccess b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/.htaccess new file mode 100644 index 0000000..32d8591 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/.htaccess @@ -0,0 +1,3 @@ + +Deny from all + \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/api.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/api.php new file mode 100644 index 0000000..f9b6895 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/api.php @@ -0,0 +1,29 @@ + auto_literal = false; + $smarty->deprecation_notices = false; + + $smarty-> cachee_dir = dirname(dirname(__FILE__)) . '/temp/cache'; + $smarty-> compile_dir = dirname(dirname(__FILE__)) . '/temp/compile'; + $smarty->template_dir = dirname(dirname(__FILE__)) . '/templates'; + + $smarty->assign('id', $id); + $smarty->assign('name', $name); + $smarty->assign('value', $value); + + $smarty->assign('root', $wysiwyg_root); + $smarty->assign('names', $wysiwyg_names); + $smarty->assign('lists', $wysiwyg_lists); + + return $smarty->fetch('wysiwyg/wysiwyg.html'); +} + +?> \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/data.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/data.php new file mode 100644 index 0000000..8ed4d05 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/data.php @@ -0,0 +1,87 @@ + 'Font name', + 'Arial, Sans-Serif' => 'Arial', + 'Comic Sans MS' => 'Comic Sans MS', + 'Courier New, Monospace' => 'Courier New', + 'Georgia, Serif' => 'Georgia', + 'Impact, Sans-Serif' => 'Impact', + 'Tahoma, Sans-Serif' => 'Tahoma', + 'Times New Roman, Serif' => 'Times New Roman', + 'Verdana, Sans-Serif' => 'Verdana'); + + +$wysiwyg_lists['smileys'] = array(); + +$handle = opendir(dirname(dirname(__FILE__)) . '/images/smileys/'); +if (is_resource($handle)) +{ + while (true) + { + $name = readdir($handle); + if (!is_string($name)) break; + if ($name === '.') continue; + if ($name === '..') continue; + $wysiwyg_lists['smileys'][] = $name; + } + closedir($handle); +} + + +$wysiwyg_lists['sizes'] = array( + '' => 'Font size', + '1' => '1', + '2' => '2', + '3' => '3', + '4' => '4', + '5' => '5', + '6' => '6', + '7' => '7'); + + +$wysiwyg_lists['colors'] = array(); + + $x = 0; + $y = 0; +for ($r = 0; $r < 6; $r++) +for ($g = 0; $g < 6; $g++) +for ($b = 0; $b < 6; $b++) +{ + $wysiwyg_lists['colors'][] = array( + 'x1' => $x*8+2, + 'y1' => $y*8+2, + 'x2' => $x*8+8, + 'y2' => $y*8+8, + 'color' => str_pad(dechex((int)(0xFF*$r/5)*0x100*0x100+ + (int)(0xFF*$g/5)*0x100+ + (int)(0xFF*$b/5)), 6, 0, STR_PAD_LEFT)); + if ($x == 17) $y++; + if ($x != 17) $x++; else $x = 0; +} + + +?> \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/init.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/init.php new file mode 100644 index 0000000..14a015d --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/php/init.php @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/.htaccess b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/.htaccess new file mode 100644 index 0000000..32d8591 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/.htaccess @@ -0,0 +1,3 @@ + +Deny from all + \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Config_File.class.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Config_File.class.php new file mode 100644 index 0000000..5787ad1 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Config_File.class.php @@ -0,0 +1,393 @@ + + * @access public + * @package Smarty + */ + +/* $Id: Config_File.class.php 3149 2009-05-23 20:59:25Z monte.ohrt $ */ + +/** + * Config file reading class + * @package Smarty + */ +class Config_File { + /**#@+ + * Options + * @var boolean + */ + /** + * Controls whether variables with the same name overwrite each other. + */ + var $overwrite = true; + + /** + * Controls whether config values of on/true/yes and off/false/no get + * converted to boolean values automatically. + */ + var $booleanize = true; + + /** + * Controls whether hidden config sections/vars are read from the file. + */ + var $read_hidden = true; + + /** + * Controls whether or not to fix mac or dos formatted newlines. + * If set to true, \r or \r\n will be changed to \n. + */ + var $fix_newlines = true; + /**#@-*/ + + /** @access private */ + var $_config_path = ""; + var $_config_data = array(); + /**#@-*/ + + /** + * Constructs a new config file class. + * + * @param string $config_path (optional) path to the config files + */ + function Config_File($config_path = NULL) + { + if (isset($config_path)) + $this->set_path($config_path); + } + + + /** + * Set the path where configuration files can be found. + * + * @param string $config_path path to the config files + */ + function set_path($config_path) + { + if (!empty($config_path)) { + if (!is_string($config_path) || !file_exists($config_path) || !is_dir($config_path)) { + $this->_trigger_error_msg("Bad config file path '$config_path'"); + return; + } + if(substr($config_path, -1) != DIRECTORY_SEPARATOR) { + $config_path .= DIRECTORY_SEPARATOR; + } + + $this->_config_path = $config_path; + } + } + + + /** + * Retrieves config info based on the file, section, and variable name. + * + * @param string $file_name config file to get info for + * @param string $section_name (optional) section to get info for + * @param string $var_name (optional) variable to get info for + * @return string|array a value or array of values + */ + function get($file_name, $section_name = NULL, $var_name = NULL) + { + if (empty($file_name)) { + $this->_trigger_error_msg('Empty config file name'); + return; + } else { + $file_name = $this->_config_path . $file_name; + if (!isset($this->_config_data[$file_name])) + $this->load_file($file_name, false); + } + + if (!empty($var_name)) { + if (empty($section_name)) { + return $this->_config_data[$file_name]["vars"][$var_name]; + } else { + if(isset($this->_config_data[$file_name]["sections"][$section_name]["vars"][$var_name])) + return $this->_config_data[$file_name]["sections"][$section_name]["vars"][$var_name]; + else + return array(); + } + } else { + if (empty($section_name)) { + return (array)$this->_config_data[$file_name]["vars"]; + } else { + if(isset($this->_config_data[$file_name]["sections"][$section_name]["vars"])) + return (array)$this->_config_data[$file_name]["sections"][$section_name]["vars"]; + else + return array(); + } + } + } + + + /** + * Retrieves config info based on the key. + * + * @param $file_name string config key (filename/section/var) + * @return string|array same as get() + * @uses get() retrieves information from config file and returns it + */ + function &get_key($config_key) + { + list($file_name, $section_name, $var_name) = explode('/', $config_key, 3); + $result = &$this->get($file_name, $section_name, $var_name); + return $result; + } + + /** + * Get all loaded config file names. + * + * @return array an array of loaded config file names + */ + function get_file_names() + { + return array_keys($this->_config_data); + } + + + /** + * Get all section names from a loaded file. + * + * @param string $file_name config file to get section names from + * @return array an array of section names from the specified file + */ + function get_section_names($file_name) + { + $file_name = $this->_config_path . $file_name; + if (!isset($this->_config_data[$file_name])) { + $this->_trigger_error_msg("Unknown config file '$file_name'"); + return; + } + + return array_keys($this->_config_data[$file_name]["sections"]); + } + + + /** + * Get all global or section variable names. + * + * @param string $file_name config file to get info for + * @param string $section_name (optional) section to get info for + * @return array an array of variables names from the specified file/section + */ + function get_var_names($file_name, $section = NULL) + { + if (empty($file_name)) { + $this->_trigger_error_msg('Empty config file name'); + return; + } else if (!isset($this->_config_data[$file_name])) { + $this->_trigger_error_msg("Unknown config file '$file_name'"); + return; + } + + if (empty($section)) + return array_keys($this->_config_data[$file_name]["vars"]); + else + return array_keys($this->_config_data[$file_name]["sections"][$section]["vars"]); + } + + + /** + * Clear loaded config data for a certain file or all files. + * + * @param string $file_name file to clear config data for + */ + function clear($file_name = NULL) + { + if ($file_name === NULL) + $this->_config_data = array(); + else if (isset($this->_config_data[$file_name])) + $this->_config_data[$file_name] = array(); + } + + + /** + * Load a configuration file manually. + * + * @param string $file_name file name to load + * @param boolean $prepend_path whether current config path should be + * prepended to the filename + */ + function load_file($file_name, $prepend_path = true) + { + if ($prepend_path && $this->_config_path != "") + $config_file = $this->_config_path . $file_name; + else + $config_file = $file_name; + + ini_set('track_errors', true); + $fp = @fopen($config_file, "r"); + if (!is_resource($fp)) { + $this->_trigger_error_msg("Could not open config file '$config_file'"); + return false; + } + + $contents = ($size = filesize($config_file)) ? fread($fp, $size) : ''; + fclose($fp); + + $this->_config_data[$config_file] = $this->parse_contents($contents); + return true; + } + + /** + * Store the contents of a file manually. + * + * @param string $config_file file name of the related contents + * @param string $contents the file-contents to parse + */ + function set_file_contents($config_file, $contents) + { + $this->_config_data[$config_file] = $this->parse_contents($contents); + return true; + } + + /** + * parse the source of a configuration file manually. + * + * @param string $contents the file-contents to parse + */ + function parse_contents($contents) + { + if($this->fix_newlines) { + // fix mac/dos formatted newlines + $contents = preg_replace('!\r\n?!', "\n", $contents); + } + + $config_data = array(); + $config_data['sections'] = array(); + $config_data['vars'] = array(); + + /* reference to fill with data */ + $vars =& $config_data['vars']; + + /* parse file line by line */ + preg_match_all('!^.*\r?\n?!m', $contents, $match); + $lines = $match[0]; + for ($i=0, $count=count($lines); $i<$count; $i++) { + $line = $lines[$i]; + if (empty($line)) continue; + + if ( substr($line, 0, 1) == '[' && preg_match('!^\[(.*?)\]!', $line, $match) ) { + /* section found */ + if (substr($match[1], 0, 1) == '.') { + /* hidden section */ + if ($this->read_hidden) { + $section_name = substr($match[1], 1); + } else { + /* break reference to $vars to ignore hidden section */ + unset($vars); + $vars = array(); + continue; + } + } else { + $section_name = $match[1]; + } + if (!isset($config_data['sections'][$section_name])) + $config_data['sections'][$section_name] = array('vars' => array()); + $vars =& $config_data['sections'][$section_name]['vars']; + continue; + } + + if (preg_match('/^\s*(\.?\w+)\s*=\s*(.*)/s', $line, $match)) { + /* variable found */ + $var_name = rtrim($match[1]); + if (strpos($match[2], '"""') === 0) { + /* handle multiline-value */ + $lines[$i] = substr($match[2], 3); + $var_value = ''; + while ($i<$count) { + if (($pos = strpos($lines[$i], '"""')) === false) { + $var_value .= $lines[$i++]; + } else { + /* end of multiline-value */ + $var_value .= substr($lines[$i], 0, $pos); + break; + } + } + $booleanize = false; + + } else { + /* handle simple value */ + $var_value = preg_replace('/^([\'"])(.*)\1$/', '\2', rtrim($match[2])); + $booleanize = $this->booleanize; + + } + $this->_set_config_var($vars, $var_name, $var_value, $booleanize); + } + /* else unparsable line / means it is a comment / means ignore it */ + } + return $config_data; + } + + /**#@+ @access private */ + /** + * @param array &$container + * @param string $var_name + * @param mixed $var_value + * @param boolean $booleanize determines whether $var_value is converted to + * to true/false + */ + function _set_config_var(&$container, $var_name, $var_value, $booleanize) + { + if (substr($var_name, 0, 1) == '.') { + if (!$this->read_hidden) + return; + else + $var_name = substr($var_name, 1); + } + + if (!preg_match("/^[a-zA-Z_]\w*$/", $var_name)) { + $this->_trigger_error_msg("Bad variable name '$var_name'"); + return; + } + + if ($booleanize) { + if (preg_match("/^(on|true|yes)$/i", $var_value)) + $var_value = true; + else if (preg_match("/^(off|false|no)$/i", $var_value)) + $var_value = false; + } + + if (!isset($container[$var_name]) || $this->overwrite) + $container[$var_name] = $var_value; + else { + settype($container[$var_name], 'array'); + $container[$var_name][] = $var_value; + } + } + + /** + * @uses trigger_error() creates a PHP warning/error + * @param string $error_msg + * @param integer $error_type one of + */ + function _trigger_error_msg($error_msg, $error_type = E_USER_WARNING) + { + trigger_error("Config_File error: $error_msg", $error_type); + } + /**#@-*/ +} + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty.class.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty.class.php new file mode 100644 index 0000000..e7298f2 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty.class.php @@ -0,0 +1,1961 @@ + + * @author Andrei Zmievski + * @package Smarty + * @version 2.6.26 + */ + +/* $Id: Smarty.class.php 3163 2009-06-17 14:39:24Z monte.ohrt $ */ + +/** + * DIR_SEP isn't used anymore, but third party apps might + */ +if(!defined('DIR_SEP')) { + define('DIR_SEP', DIRECTORY_SEPARATOR); +} + +/** + * set SMARTY_DIR to absolute path to Smarty library files. + * if not defined, include_path will be used. Sets SMARTY_DIR only if user + * application has not already defined it. + */ + +if (!defined('SMARTY_DIR')) { + define('SMARTY_DIR', dirname(__FILE__) . DIRECTORY_SEPARATOR); +} + +if (!defined('SMARTY_CORE_DIR')) { + define('SMARTY_CORE_DIR', SMARTY_DIR . 'internals' . DIRECTORY_SEPARATOR); +} + +define('SMARTY_PHP_PASSTHRU', 0); +define('SMARTY_PHP_QUOTE', 1); +define('SMARTY_PHP_REMOVE', 2); +define('SMARTY_PHP_ALLOW', 3); + +/** + * @package Smarty + */ +class Smarty +{ + /**#@+ + * Smarty Configuration Section + */ + + /** + * The name of the directory where templates are located. + * + * @var string + */ + var $template_dir = 'templates'; + + /** + * The directory where compiled templates are located. + * + * @var string + */ + var $compile_dir = 'templates_c'; + + /** + * The directory where config files are located. + * + * @var string + */ + var $config_dir = 'configs'; + + /** + * An array of directories searched for plugins. + * + * @var array + */ + var $plugins_dir = array('plugins'); + + /** + * If debugging is enabled, a debug console window will display + * when the page loads (make sure your browser allows unrequested + * popup windows) + * + * @var boolean + */ + var $debugging = false; + + /** + * When set, smarty does uses this value as error_reporting-level. + * + * @var integer + */ + var $error_reporting = null; + + /** + * This is the path to the debug console template. If not set, + * the default one will be used. + * + * @var string + */ + var $debug_tpl = ''; + + /** + * This determines if debugging is enable-able from the browser. + *
    + *
  • NONE => no debugging control allowed
  • + *
  • URL => enable debugging when SMARTY_DEBUG is found in the URL.
  • + *
+ * @link http://www.foo.dom/index.php?SMARTY_DEBUG + * @var string + */ + var $debugging_ctrl = 'NONE'; + + /** + * This tells Smarty whether to check for recompiling or not. Recompiling + * does not need to happen unless a template or config file is changed. + * Typically you enable this during development, and disable for + * production. + * + * @var boolean + */ + var $compile_check = true; + + /** + * This forces templates to compile every time. Useful for development + * or debugging. + * + * @var boolean + */ + var $force_compile = false; + + /** + * This enables template caching. + *
    + *
  • 0 = no caching
  • + *
  • 1 = use class cache_lifetime value
  • + *
  • 2 = use cache_lifetime in cache file
  • + *
+ * @var integer + */ + var $caching = 0; + + /** + * The name of the directory for cache files. + * + * @var string + */ + var $cache_dir = 'cache'; + + /** + * This is the number of seconds cached content will persist. + *
    + *
  • 0 = always regenerate cache
  • + *
  • -1 = never expires
  • + *
+ * + * @var integer + */ + var $cache_lifetime = 3600; + + /** + * Only used when $caching is enabled. If true, then If-Modified-Since headers + * are respected with cached content, and appropriate HTTP headers are sent. + * This way repeated hits to a cached page do not send the entire page to the + * client every time. + * + * @var boolean + */ + var $cache_modified_check = false; + + /** + * This determines how Smarty handles "" tags in templates. + * possible values: + *
    + *
  • SMARTY_PHP_PASSTHRU -> print tags as plain text
  • + *
  • SMARTY_PHP_QUOTE -> escape tags as entities
  • + *
  • SMARTY_PHP_REMOVE -> remove php tags
  • + *
  • SMARTY_PHP_ALLOW -> execute php tags
  • + *
+ * + * @var integer + */ + var $php_handling = SMARTY_PHP_PASSTHRU; + + /** + * This enables template security. When enabled, many things are restricted + * in the templates that normally would go unchecked. This is useful when + * untrusted parties are editing templates and you want a reasonable level + * of security. (no direct execution of PHP in templates for example) + * + * @var boolean + */ + var $security = false; + + /** + * This is the list of template directories that are considered secure. This + * is used only if {@link $security} is enabled. One directory per array + * element. {@link $template_dir} is in this list implicitly. + * + * @var array + */ + var $secure_dir = array(); + + /** + * These are the security settings for Smarty. They are used only when + * {@link $security} is enabled. + * + * @var array + */ + var $security_settings = array( + 'PHP_HANDLING' => false, + 'IF_FUNCS' => array('array', 'list', + 'isset', 'empty', + 'count', 'sizeof', + 'in_array', 'is_array', + 'true', 'false', 'null'), + 'INCLUDE_ANY' => false, + 'PHP_TAGS' => false, + 'MODIFIER_FUNCS' => array('count'), + 'ALLOW_CONSTANTS' => false, + 'ALLOW_SUPER_GLOBALS' => true + ); + + /** + * This is an array of directories where trusted php scripts reside. + * {@link $security} is disabled during their inclusion/execution. + * + * @var array + */ + var $trusted_dir = array(); + + /** + * The left delimiter used for the template tags. + * + * @var string + */ + var $left_delimiter = '{'; + + /** + * The right delimiter used for the template tags. + * + * @var string + */ + var $right_delimiter = '}'; + + /** + * The order in which request variables are registered, similar to + * variables_order in php.ini E = Environment, G = GET, P = POST, + * C = Cookies, S = Server + * + * @var string + */ + var $request_vars_order = 'EGPCS'; + + /** + * Indicates wether $HTTP_*_VARS[] (request_use_auto_globals=false) + * are uses as request-vars or $_*[]-vars. note: if + * request_use_auto_globals is true, then $request_vars_order has + * no effect, but the php-ini-value "gpc_order" + * + * @var boolean + */ + var $request_use_auto_globals = true; + + /** + * Set this if you want different sets of compiled files for the same + * templates. This is useful for things like different languages. + * Instead of creating separate sets of templates per language, you + * set different compile_ids like 'en' and 'de'. + * + * @var string + */ + var $compile_id = null; + + /** + * This tells Smarty whether or not to use sub dirs in the cache/ and + * templates_c/ directories. sub directories better organized, but + * may not work well with PHP safe mode enabled. + * + * @var boolean + * + */ + var $use_sub_dirs = false; + + /** + * This is a list of the modifiers to apply to all template variables. + * Put each modifier in a separate array element in the order you want + * them applied. example: array('escape:"htmlall"'); + * + * @var array + */ + var $default_modifiers = array(); + + /** + * This is the resource type to be used when not specified + * at the beginning of the resource path. examples: + * $smarty->display('file:index.tpl'); + * $smarty->display('db:index.tpl'); + * $smarty->display('index.tpl'); // will use default resource type + * {include file="file:index.tpl"} + * {include file="db:index.tpl"} + * {include file="index.tpl"} {* will use default resource type *} + * + * @var array + */ + var $default_resource_type = 'file'; + + /** + * The function used for cache file handling. If not set, built-in caching is used. + * + * @var null|string function name + */ + var $cache_handler_func = null; + + /** + * This indicates which filters are automatically loaded into Smarty. + * + * @var array array of filter names + */ + var $autoload_filters = array(); + + /**#@+ + * @var boolean + */ + /** + * This tells if config file vars of the same name overwrite each other or not. + * if disabled, same name variables are accumulated in an array. + */ + var $config_overwrite = true; + + /** + * This tells whether or not to automatically booleanize config file variables. + * If enabled, then the strings "on", "true", and "yes" are treated as boolean + * true, and "off", "false" and "no" are treated as boolean false. + */ + var $config_booleanize = true; + + /** + * This tells whether hidden sections [.foobar] are readable from the + * tempalates or not. Normally you would never allow this since that is + * the point behind hidden sections: the application can access them, but + * the templates cannot. + */ + var $config_read_hidden = false; + + /** + * This tells whether or not automatically fix newlines in config files. + * It basically converts \r (mac) or \r\n (dos) to \n + */ + var $config_fix_newlines = true; + /**#@-*/ + + /** + * If a template cannot be found, this PHP function will be executed. + * Useful for creating templates on-the-fly or other special action. + * + * @var string function name + */ + var $default_template_handler_func = ''; + + /** + * The file that contains the compiler class. This can a full + * pathname, or relative to the php_include path. + * + * @var string + */ + var $compiler_file = 'Smarty_Compiler.class.php'; + + /** + * The class used for compiling templates. + * + * @var string + */ + var $compiler_class = 'Smarty_Compiler'; + + /** + * The class used to load config vars. + * + * @var string + */ + var $config_class = 'Config_File'; + +/**#@+ + * END Smarty Configuration Section + * There should be no need to touch anything below this line. + * @access private + */ + /** + * where assigned template vars are kept + * + * @var array + */ + var $_tpl_vars = array(); + + /** + * stores run-time $smarty.* vars + * + * @var null|array + */ + var $_smarty_vars = null; + + /** + * keeps track of sections + * + * @var array + */ + var $_sections = array(); + + /** + * keeps track of foreach blocks + * + * @var array + */ + var $_foreach = array(); + + /** + * keeps track of tag hierarchy + * + * @var array + */ + var $_tag_stack = array(); + + /** + * configuration object + * + * @var Config_file + */ + var $_conf_obj = null; + + /** + * loaded configuration settings + * + * @var array + */ + var $_config = array(array('vars' => array(), 'files' => array())); + + /** + * md5 checksum of the string 'Smarty' + * + * @var string + */ + var $_smarty_md5 = 'f8d698aea36fcbead2b9d5359ffca76f'; + + /** + * Smarty version number + * + * @var string + */ + var $_version = '2.6.26'; + + /** + * current template inclusion depth + * + * @var integer + */ + var $_inclusion_depth = 0; + + /** + * for different compiled templates + * + * @var string + */ + var $_compile_id = null; + + /** + * text in URL to enable debug mode + * + * @var string + */ + var $_smarty_debug_id = 'SMARTY_DEBUG'; + + /** + * debugging information for debug console + * + * @var array + */ + var $_smarty_debug_info = array(); + + /** + * info that makes up a cache file + * + * @var array + */ + var $_cache_info = array(); + + /** + * default file permissions + * + * @var integer + */ + var $_file_perms = 0644; + + /** + * default dir permissions + * + * @var integer + */ + var $_dir_perms = 0771; + + /** + * registered objects + * + * @var array + */ + var $_reg_objects = array(); + + /** + * table keeping track of plugins + * + * @var array + */ + var $_plugins = array( + 'modifier' => array(), + 'function' => array(), + 'block' => array(), + 'compiler' => array(), + 'prefilter' => array(), + 'postfilter' => array(), + 'outputfilter' => array(), + 'resource' => array(), + 'insert' => array()); + + + /** + * cache serials + * + * @var array + */ + var $_cache_serials = array(); + + /** + * name of optional cache include file + * + * @var string + */ + var $_cache_include = null; + + /** + * indicate if the current code is used in a compiled + * include + * + * @var string + */ + var $_cache_including = false; + + /**#@-*/ + /** + * The class constructor. + */ + function Smarty() + { + $this->assign('SCRIPT_NAME', isset($_SERVER['SCRIPT_NAME']) ? $_SERVER['SCRIPT_NAME'] + : @$GLOBALS['HTTP_SERVER_VARS']['SCRIPT_NAME']); + } + + /** + * assigns values to template variables + * + * @param array|string $tpl_var the template variable name(s) + * @param mixed $value the value to assign + */ + function assign($tpl_var, $value = null) + { + if (is_array($tpl_var)){ + foreach ($tpl_var as $key => $val) { + if ($key != '') { + $this->_tpl_vars[$key] = $val; + } + } + } else { + if ($tpl_var != '') + $this->_tpl_vars[$tpl_var] = $value; + } + } + + /** + * assigns values to template variables by reference + * + * @param string $tpl_var the template variable name + * @param mixed $value the referenced value to assign + */ + function assign_by_ref($tpl_var, &$value) + { + if ($tpl_var != '') + $this->_tpl_vars[$tpl_var] = &$value; + } + + /** + * appends values to template variables + * + * @param array|string $tpl_var the template variable name(s) + * @param mixed $value the value to append + */ + function append($tpl_var, $value=null, $merge=false) + { + if (is_array($tpl_var)) { + // $tpl_var is an array, ignore $value + foreach ($tpl_var as $_key => $_val) { + if ($_key != '') { + if(!@is_array($this->_tpl_vars[$_key])) { + settype($this->_tpl_vars[$_key],'array'); + } + if($merge && is_array($_val)) { + foreach($_val as $_mkey => $_mval) { + $this->_tpl_vars[$_key][$_mkey] = $_mval; + } + } else { + $this->_tpl_vars[$_key][] = $_val; + } + } + } + } else { + if ($tpl_var != '' && isset($value)) { + if(!@is_array($this->_tpl_vars[$tpl_var])) { + settype($this->_tpl_vars[$tpl_var],'array'); + } + if($merge && is_array($value)) { + foreach($value as $_mkey => $_mval) { + $this->_tpl_vars[$tpl_var][$_mkey] = $_mval; + } + } else { + $this->_tpl_vars[$tpl_var][] = $value; + } + } + } + } + + /** + * appends values to template variables by reference + * + * @param string $tpl_var the template variable name + * @param mixed $value the referenced value to append + */ + function append_by_ref($tpl_var, &$value, $merge=false) + { + if ($tpl_var != '' && isset($value)) { + if(!@is_array($this->_tpl_vars[$tpl_var])) { + settype($this->_tpl_vars[$tpl_var],'array'); + } + if ($merge && is_array($value)) { + foreach($value as $_key => $_val) { + $this->_tpl_vars[$tpl_var][$_key] = &$value[$_key]; + } + } else { + $this->_tpl_vars[$tpl_var][] = &$value; + } + } + } + + + /** + * clear the given assigned template variable. + * + * @param string $tpl_var the template variable to clear + */ + function clear_assign($tpl_var) + { + if (is_array($tpl_var)) + foreach ($tpl_var as $curr_var) + unset($this->_tpl_vars[$curr_var]); + else + unset($this->_tpl_vars[$tpl_var]); + } + + + /** + * Registers custom function to be used in templates + * + * @param string $function the name of the template function + * @param string $function_impl the name of the PHP function to register + */ + function register_function($function, $function_impl, $cacheable=true, $cache_attrs=null) + { + $this->_plugins['function'][$function] = + array($function_impl, null, null, false, $cacheable, $cache_attrs); + + } + + /** + * Unregisters custom function + * + * @param string $function name of template function + */ + function unregister_function($function) + { + unset($this->_plugins['function'][$function]); + } + + /** + * Registers object to be used in templates + * + * @param string $object name of template object + * @param object &$object_impl the referenced PHP object to register + * @param null|array $allowed list of allowed methods (empty = all) + * @param boolean $smarty_args smarty argument format, else traditional + * @param null|array $block_functs list of methods that are block format + */ + function register_object($object, &$object_impl, $allowed = array(), $smarty_args = true, $block_methods = array()) + { + settype($allowed, 'array'); + settype($smarty_args, 'boolean'); + $this->_reg_objects[$object] = + array(&$object_impl, $allowed, $smarty_args, $block_methods); + } + + /** + * Unregisters object + * + * @param string $object name of template object + */ + function unregister_object($object) + { + unset($this->_reg_objects[$object]); + } + + + /** + * Registers block function to be used in templates + * + * @param string $block name of template block + * @param string $block_impl PHP function to register + */ + function register_block($block, $block_impl, $cacheable=true, $cache_attrs=null) + { + $this->_plugins['block'][$block] = + array($block_impl, null, null, false, $cacheable, $cache_attrs); + } + + /** + * Unregisters block function + * + * @param string $block name of template function + */ + function unregister_block($block) + { + unset($this->_plugins['block'][$block]); + } + + /** + * Registers compiler function + * + * @param string $function name of template function + * @param string $function_impl name of PHP function to register + */ + function register_compiler_function($function, $function_impl, $cacheable=true) + { + $this->_plugins['compiler'][$function] = + array($function_impl, null, null, false, $cacheable); + } + + /** + * Unregisters compiler function + * + * @param string $function name of template function + */ + function unregister_compiler_function($function) + { + unset($this->_plugins['compiler'][$function]); + } + + /** + * Registers modifier to be used in templates + * + * @param string $modifier name of template modifier + * @param string $modifier_impl name of PHP function to register + */ + function register_modifier($modifier, $modifier_impl) + { + $this->_plugins['modifier'][$modifier] = + array($modifier_impl, null, null, false); + } + + /** + * Unregisters modifier + * + * @param string $modifier name of template modifier + */ + function unregister_modifier($modifier) + { + unset($this->_plugins['modifier'][$modifier]); + } + + /** + * Registers a resource to fetch a template + * + * @param string $type name of resource + * @param array $functions array of functions to handle resource + */ + function register_resource($type, $functions) + { + if (count($functions)==4) { + $this->_plugins['resource'][$type] = + array($functions, false); + + } elseif (count($functions)==5) { + $this->_plugins['resource'][$type] = + array(array(array(&$functions[0], $functions[1]) + ,array(&$functions[0], $functions[2]) + ,array(&$functions[0], $functions[3]) + ,array(&$functions[0], $functions[4])) + ,false); + + } else { + $this->trigger_error("malformed function-list for '$type' in register_resource"); + + } + } + + /** + * Unregisters a resource + * + * @param string $type name of resource + */ + function unregister_resource($type) + { + unset($this->_plugins['resource'][$type]); + } + + /** + * Registers a prefilter function to apply + * to a template before compiling + * + * @param callback $function + */ + function register_prefilter($function) + { + $this->_plugins['prefilter'][$this->_get_filter_name($function)] + = array($function, null, null, false); + } + + /** + * Unregisters a prefilter function + * + * @param callback $function + */ + function unregister_prefilter($function) + { + unset($this->_plugins['prefilter'][$this->_get_filter_name($function)]); + } + + /** + * Registers a postfilter function to apply + * to a compiled template after compilation + * + * @param callback $function + */ + function register_postfilter($function) + { + $this->_plugins['postfilter'][$this->_get_filter_name($function)] + = array($function, null, null, false); + } + + /** + * Unregisters a postfilter function + * + * @param callback $function + */ + function unregister_postfilter($function) + { + unset($this->_plugins['postfilter'][$this->_get_filter_name($function)]); + } + + /** + * Registers an output filter function to apply + * to a template output + * + * @param callback $function + */ + function register_outputfilter($function) + { + $this->_plugins['outputfilter'][$this->_get_filter_name($function)] + = array($function, null, null, false); + } + + /** + * Unregisters an outputfilter function + * + * @param callback $function + */ + function unregister_outputfilter($function) + { + unset($this->_plugins['outputfilter'][$this->_get_filter_name($function)]); + } + + /** + * load a filter of specified type and name + * + * @param string $type filter type + * @param string $name filter name + */ + function load_filter($type, $name) + { + switch ($type) { + case 'output': + $_params = array('plugins' => array(array($type . 'filter', $name, null, null, false))); + require_once(SMARTY_CORE_DIR . 'core.load_plugins.php'); + smarty_core_load_plugins($_params, $this); + break; + + case 'pre': + case 'post': + if (!isset($this->_plugins[$type . 'filter'][$name])) + $this->_plugins[$type . 'filter'][$name] = false; + break; + } + } + + /** + * clear cached content for the given template and cache id + * + * @param string $tpl_file name of template file + * @param string $cache_id name of cache_id + * @param string $compile_id name of compile_id + * @param string $exp_time expiration time + * @return boolean + */ + function clear_cache($tpl_file = null, $cache_id = null, $compile_id = null, $exp_time = null) + { + + if (!isset($compile_id)) + $compile_id = $this->compile_id; + + if (!isset($tpl_file)) + $compile_id = null; + + $_auto_id = $this->_get_auto_id($cache_id, $compile_id); + + if (!empty($this->cache_handler_func)) { + return call_user_func_array($this->cache_handler_func, + array('clear', &$this, &$dummy, $tpl_file, $cache_id, $compile_id, $exp_time)); + } else { + $_params = array('auto_base' => $this->cache_dir, + 'auto_source' => $tpl_file, + 'auto_id' => $_auto_id, + 'exp_time' => $exp_time); + require_once(SMARTY_CORE_DIR . 'core.rm_auto.php'); + return smarty_core_rm_auto($_params, $this); + } + + } + + + /** + * clear the entire contents of cache (all templates) + * + * @param string $exp_time expire time + * @return boolean results of {@link smarty_core_rm_auto()} + */ + function clear_all_cache($exp_time = null) + { + return $this->clear_cache(null, null, null, $exp_time); + } + + + /** + * test to see if valid cache exists for this template + * + * @param string $tpl_file name of template file + * @param string $cache_id + * @param string $compile_id + * @return string|false results of {@link _read_cache_file()} + */ + function is_cached($tpl_file, $cache_id = null, $compile_id = null) + { + if (!$this->caching) + return false; + + if (!isset($compile_id)) + $compile_id = $this->compile_id; + + $_params = array( + 'tpl_file' => $tpl_file, + 'cache_id' => $cache_id, + 'compile_id' => $compile_id + ); + require_once(SMARTY_CORE_DIR . 'core.read_cache_file.php'); + return smarty_core_read_cache_file($_params, $this); + } + + + /** + * clear all the assigned template variables. + * + */ + function clear_all_assign() + { + $this->_tpl_vars = array(); + } + + /** + * clears compiled version of specified template resource, + * or all compiled template files if one is not specified. + * This function is for advanced use only, not normally needed. + * + * @param string $tpl_file + * @param string $compile_id + * @param string $exp_time + * @return boolean results of {@link smarty_core_rm_auto()} + */ + function clear_compiled_tpl($tpl_file = null, $compile_id = null, $exp_time = null) + { + if (!isset($compile_id)) { + $compile_id = $this->compile_id; + } + $_params = array('auto_base' => $this->compile_dir, + 'auto_source' => $tpl_file, + 'auto_id' => $compile_id, + 'exp_time' => $exp_time, + 'extensions' => array('.inc', '.php')); + require_once(SMARTY_CORE_DIR . 'core.rm_auto.php'); + return smarty_core_rm_auto($_params, $this); + } + + /** + * Checks whether requested template exists. + * + * @param string $tpl_file + * @return boolean + */ + function template_exists($tpl_file) + { + $_params = array('resource_name' => $tpl_file, 'quiet'=>true, 'get_source'=>false); + return $this->_fetch_resource_info($_params); + } + + /** + * Returns an array containing template variables + * + * @param string $name + * @param string $type + * @return array + */ + function &get_template_vars($name=null) + { + if(!isset($name)) { + return $this->_tpl_vars; + } elseif(isset($this->_tpl_vars[$name])) { + return $this->_tpl_vars[$name]; + } else { + // var non-existant, return valid reference + $_tmp = null; + return $_tmp; + } + } + + /** + * Returns an array containing config variables + * + * @param string $name + * @param string $type + * @return array + */ + function &get_config_vars($name=null) + { + if(!isset($name) && is_array($this->_config[0])) { + return $this->_config[0]['vars']; + } else if(isset($this->_config[0]['vars'][$name])) { + return $this->_config[0]['vars'][$name]; + } else { + // var non-existant, return valid reference + $_tmp = null; + return $_tmp; + } + } + + /** + * trigger Smarty error + * + * @param string $error_msg + * @param integer $error_type + */ + function trigger_error($error_msg, $error_type = E_USER_WARNING) + { + trigger_error("Smarty error: $error_msg", $error_type); + } + + + /** + * executes & displays the template results + * + * @param string $resource_name + * @param string $cache_id + * @param string $compile_id + */ + function display($resource_name, $cache_id = null, $compile_id = null) + { + $this->fetch($resource_name, $cache_id, $compile_id, true); + } + + /** + * executes & returns or displays the template results + * + * @param string $resource_name + * @param string $cache_id + * @param string $compile_id + * @param boolean $display + */ + function fetch($resource_name, $cache_id = null, $compile_id = null, $display = false) + { + static $_cache_info = array(); + + $_smarty_old_error_level = $this->debugging ? error_reporting() : error_reporting(isset($this->error_reporting) + ? $this->error_reporting : error_reporting() & ~E_NOTICE); + + if (!$this->debugging && $this->debugging_ctrl == 'URL') { + $_query_string = $this->request_use_auto_globals ? $_SERVER['QUERY_STRING'] : $GLOBALS['HTTP_SERVER_VARS']['QUERY_STRING']; + if (@strstr($_query_string, $this->_smarty_debug_id)) { + if (@strstr($_query_string, $this->_smarty_debug_id . '=on')) { + // enable debugging for this browser session + @setcookie('SMARTY_DEBUG', true); + $this->debugging = true; + } elseif (@strstr($_query_string, $this->_smarty_debug_id . '=off')) { + // disable debugging for this browser session + @setcookie('SMARTY_DEBUG', false); + $this->debugging = false; + } else { + // enable debugging for this page + $this->debugging = true; + } + } else { + $this->debugging = (bool)($this->request_use_auto_globals ? @$_COOKIE['SMARTY_DEBUG'] : @$GLOBALS['HTTP_COOKIE_VARS']['SMARTY_DEBUG']); + } + } + + if ($this->debugging) { + // capture time for debugging info + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $_debug_start_time = smarty_core_get_microtime($_params, $this); + $this->_smarty_debug_info[] = array('type' => 'template', + 'filename' => $resource_name, + 'depth' => 0); + $_included_tpls_idx = count($this->_smarty_debug_info) - 1; + } + + if (!isset($compile_id)) { + $compile_id = $this->compile_id; + } + + $this->_compile_id = $compile_id; + $this->_inclusion_depth = 0; + + if ($this->caching) { + // save old cache_info, initialize cache_info + array_push($_cache_info, $this->_cache_info); + $this->_cache_info = array(); + $_params = array( + 'tpl_file' => $resource_name, + 'cache_id' => $cache_id, + 'compile_id' => $compile_id, + 'results' => null + ); + require_once(SMARTY_CORE_DIR . 'core.read_cache_file.php'); + if (smarty_core_read_cache_file($_params, $this)) { + $_smarty_results = $_params['results']; + if (!empty($this->_cache_info['insert_tags'])) { + $_params = array('plugins' => $this->_cache_info['insert_tags']); + require_once(SMARTY_CORE_DIR . 'core.load_plugins.php'); + smarty_core_load_plugins($_params, $this); + $_params = array('results' => $_smarty_results); + require_once(SMARTY_CORE_DIR . 'core.process_cached_inserts.php'); + $_smarty_results = smarty_core_process_cached_inserts($_params, $this); + } + if (!empty($this->_cache_info['cache_serials'])) { + $_params = array('results' => $_smarty_results); + require_once(SMARTY_CORE_DIR . 'core.process_compiled_include.php'); + $_smarty_results = smarty_core_process_compiled_include($_params, $this); + } + + + if ($display) { + if ($this->debugging) + { + // capture time for debugging info + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $this->_smarty_debug_info[$_included_tpls_idx]['exec_time'] = smarty_core_get_microtime($_params, $this) - $_debug_start_time; + require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php'); + $_smarty_results .= smarty_core_display_debug_console($_params, $this); + } + if ($this->cache_modified_check) { + $_server_vars = ($this->request_use_auto_globals) ? $_SERVER : $GLOBALS['HTTP_SERVER_VARS']; + $_last_modified_date = @substr($_server_vars['HTTP_IF_MODIFIED_SINCE'], 0, strpos($_server_vars['HTTP_IF_MODIFIED_SINCE'], 'GMT') + 3); + $_gmt_mtime = gmdate('D, d M Y H:i:s', $this->_cache_info['timestamp']).' GMT'; + if (@count($this->_cache_info['insert_tags']) == 0 + && !$this->_cache_serials + && $_gmt_mtime == $_last_modified_date) { + if (php_sapi_name()=='cgi') + header('Status: 304 Not Modified'); + else + header('HTTP/1.1 304 Not Modified'); + + } else { + header('Last-Modified: '.$_gmt_mtime); + echo $_smarty_results; + } + } else { + echo $_smarty_results; + } + error_reporting($_smarty_old_error_level); + // restore initial cache_info + $this->_cache_info = array_pop($_cache_info); + return true; + } else { + error_reporting($_smarty_old_error_level); + // restore initial cache_info + $this->_cache_info = array_pop($_cache_info); + return $_smarty_results; + } + } else { + $this->_cache_info['template'][$resource_name] = true; + if ($this->cache_modified_check && $display) { + header('Last-Modified: '.gmdate('D, d M Y H:i:s', time()).' GMT'); + } + } + } + + // load filters that are marked as autoload + if (count($this->autoload_filters)) { + foreach ($this->autoload_filters as $_filter_type => $_filters) { + foreach ($_filters as $_filter) { + $this->load_filter($_filter_type, $_filter); + } + } + } + + $_smarty_compile_path = $this->_get_compile_path($resource_name); + + // if we just need to display the results, don't perform output + // buffering - for speed + $_cache_including = $this->_cache_including; + $this->_cache_including = false; + if ($display && !$this->caching && count($this->_plugins['outputfilter']) == 0) { + if ($this->_is_compiled($resource_name, $_smarty_compile_path) + || $this->_compile_resource($resource_name, $_smarty_compile_path)) + { + include($_smarty_compile_path); + } + } else { + ob_start(); + if ($this->_is_compiled($resource_name, $_smarty_compile_path) + || $this->_compile_resource($resource_name, $_smarty_compile_path)) + { + include($_smarty_compile_path); + } + $_smarty_results = ob_get_contents(); + ob_end_clean(); + + foreach ((array)$this->_plugins['outputfilter'] as $_output_filter) { + $_smarty_results = call_user_func_array($_output_filter[0], array($_smarty_results, &$this)); + } + } + + if ($this->caching) { + $_params = array('tpl_file' => $resource_name, + 'cache_id' => $cache_id, + 'compile_id' => $compile_id, + 'results' => $_smarty_results); + require_once(SMARTY_CORE_DIR . 'core.write_cache_file.php'); + smarty_core_write_cache_file($_params, $this); + require_once(SMARTY_CORE_DIR . 'core.process_cached_inserts.php'); + $_smarty_results = smarty_core_process_cached_inserts($_params, $this); + + if ($this->_cache_serials) { + // strip nocache-tags from output + $_smarty_results = preg_replace('!(\{/?nocache\:[0-9a-f]{32}#\d+\})!s' + ,'' + ,$_smarty_results); + } + // restore initial cache_info + $this->_cache_info = array_pop($_cache_info); + } + $this->_cache_including = $_cache_including; + + if ($display) { + if (isset($_smarty_results)) { echo $_smarty_results; } + if ($this->debugging) { + // capture time for debugging info + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $this->_smarty_debug_info[$_included_tpls_idx]['exec_time'] = (smarty_core_get_microtime($_params, $this) - $_debug_start_time); + require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php'); + echo smarty_core_display_debug_console($_params, $this); + } + error_reporting($_smarty_old_error_level); + return; + } else { + error_reporting($_smarty_old_error_level); + if (isset($_smarty_results)) { return $_smarty_results; } + } + } + + /** + * load configuration values + * + * @param string $file + * @param string $section + * @param string $scope + */ + function config_load($file, $section = null, $scope = 'global') + { + require_once($this->_get_plugin_filepath('function', 'config_load')); + smarty_function_config_load(array('file' => $file, 'section' => $section, 'scope' => $scope), $this); + } + + /** + * return a reference to a registered object + * + * @param string $name + * @return object + */ + function &get_registered_object($name) { + if (!isset($this->_reg_objects[$name])) + $this->_trigger_fatal_error("'$name' is not a registered object"); + + if (!is_object($this->_reg_objects[$name][0])) + $this->_trigger_fatal_error("registered '$name' is not an object"); + + return $this->_reg_objects[$name][0]; + } + + /** + * clear configuration values + * + * @param string $var + */ + function clear_config($var = null) + { + if(!isset($var)) { + // clear all values + $this->_config = array(array('vars' => array(), + 'files' => array())); + } else { + unset($this->_config[0]['vars'][$var]); + } + } + + /** + * get filepath of requested plugin + * + * @param string $type + * @param string $name + * @return string|false + */ + function _get_plugin_filepath($type, $name) + { + $_params = array('type' => $type, 'name' => $name); + require_once(SMARTY_CORE_DIR . 'core.assemble_plugin_filepath.php'); + return smarty_core_assemble_plugin_filepath($_params, $this); + } + + /** + * test if resource needs compiling + * + * @param string $resource_name + * @param string $compile_path + * @return boolean + */ + function _is_compiled($resource_name, $compile_path) + { + if (!$this->force_compile && file_exists($compile_path)) { + if (!$this->compile_check) { + // no need to check compiled file + return true; + } else { + // get file source and timestamp + $_params = array('resource_name' => $resource_name, 'get_source'=>false); + if (!$this->_fetch_resource_info($_params)) { + return false; + } + if ($_params['resource_timestamp'] <= filemtime($compile_path)) { + // template not expired, no recompile + return true; + } else { + // compile template + return false; + } + } + } else { + // compiled template does not exist, or forced compile + return false; + } + } + + /** + * compile the template + * + * @param string $resource_name + * @param string $compile_path + * @return boolean + */ + function _compile_resource($resource_name, $compile_path) + { + + $_params = array('resource_name' => $resource_name); + if (!$this->_fetch_resource_info($_params)) { + return false; + } + + $_source_content = $_params['source_content']; + $_cache_include = substr($compile_path, 0, -4).'.inc'; + + if ($this->_compile_source($resource_name, $_source_content, $_compiled_content, $_cache_include)) { + // if a _cache_serial was set, we also have to write an include-file: + if ($this->_cache_include_info) { + require_once(SMARTY_CORE_DIR . 'core.write_compiled_include.php'); + smarty_core_write_compiled_include(array_merge($this->_cache_include_info, array('compiled_content'=>$_compiled_content, 'resource_name'=>$resource_name)), $this); + } + + $_params = array('compile_path'=>$compile_path, 'compiled_content' => $_compiled_content); + require_once(SMARTY_CORE_DIR . 'core.write_compiled_resource.php'); + smarty_core_write_compiled_resource($_params, $this); + + return true; + } else { + return false; + } + + } + + /** + * compile the given source + * + * @param string $resource_name + * @param string $source_content + * @param string $compiled_content + * @return boolean + */ + function _compile_source($resource_name, &$source_content, &$compiled_content, $cache_include_path=null) + { + if (file_exists(SMARTY_DIR . $this->compiler_file)) { + require_once(SMARTY_DIR . $this->compiler_file); + } else { + // use include_path + require_once($this->compiler_file); + } + + + $smarty_compiler = new $this->compiler_class; + + $smarty_compiler->template_dir = $this->template_dir; + $smarty_compiler->compile_dir = $this->compile_dir; + $smarty_compiler->plugins_dir = $this->plugins_dir; + $smarty_compiler->config_dir = $this->config_dir; + $smarty_compiler->force_compile = $this->force_compile; + $smarty_compiler->caching = $this->caching; + $smarty_compiler->php_handling = $this->php_handling; + $smarty_compiler->left_delimiter = $this->left_delimiter; + $smarty_compiler->right_delimiter = $this->right_delimiter; + $smarty_compiler->_version = $this->_version; + $smarty_compiler->security = $this->security; + $smarty_compiler->secure_dir = $this->secure_dir; + $smarty_compiler->security_settings = $this->security_settings; + $smarty_compiler->trusted_dir = $this->trusted_dir; + $smarty_compiler->use_sub_dirs = $this->use_sub_dirs; + $smarty_compiler->_reg_objects = &$this->_reg_objects; + $smarty_compiler->_plugins = &$this->_plugins; + $smarty_compiler->_tpl_vars = &$this->_tpl_vars; + $smarty_compiler->default_modifiers = $this->default_modifiers; + $smarty_compiler->compile_id = $this->_compile_id; + $smarty_compiler->_config = $this->_config; + $smarty_compiler->request_use_auto_globals = $this->request_use_auto_globals; + + if (isset($cache_include_path) && isset($this->_cache_serials[$cache_include_path])) { + $smarty_compiler->_cache_serial = $this->_cache_serials[$cache_include_path]; + } + $smarty_compiler->_cache_include = $cache_include_path; + + + $_results = $smarty_compiler->_compile_file($resource_name, $source_content, $compiled_content); + + if ($smarty_compiler->_cache_serial) { + $this->_cache_include_info = array( + 'cache_serial'=>$smarty_compiler->_cache_serial + ,'plugins_code'=>$smarty_compiler->_plugins_code + ,'include_file_path' => $cache_include_path); + + } else { + $this->_cache_include_info = null; + + } + + return $_results; + } + + /** + * Get the compile path for this resource + * + * @param string $resource_name + * @return string results of {@link _get_auto_filename()} + */ + function _get_compile_path($resource_name) + { + return $this->_get_auto_filename($this->compile_dir, $resource_name, + $this->_compile_id) . '.php'; + } + + /** + * fetch the template info. Gets timestamp, and source + * if get_source is true + * + * sets $source_content to the source of the template, and + * $resource_timestamp to its time stamp + * @param string $resource_name + * @param string $source_content + * @param integer $resource_timestamp + * @param boolean $get_source + * @param boolean $quiet + * @return boolean + */ + + function _fetch_resource_info(&$params) + { + if(!isset($params['get_source'])) { $params['get_source'] = true; } + if(!isset($params['quiet'])) { $params['quiet'] = false; } + + $_return = false; + $_params = array('resource_name' => $params['resource_name']) ; + if (isset($params['resource_base_path'])) + $_params['resource_base_path'] = $params['resource_base_path']; + else + $_params['resource_base_path'] = $this->template_dir; + + if ($this->_parse_resource_name($_params)) { + $_resource_type = $_params['resource_type']; + $_resource_name = $_params['resource_name']; + switch ($_resource_type) { + case 'file': + if ($params['get_source']) { + $params['source_content'] = $this->_read_file($_resource_name); + } + $params['resource_timestamp'] = filemtime($_resource_name); + $_return = is_file($_resource_name) && is_readable($_resource_name); + break; + + default: + // call resource functions to fetch the template source and timestamp + if ($params['get_source']) { + $_source_return = isset($this->_plugins['resource'][$_resource_type]) && + call_user_func_array($this->_plugins['resource'][$_resource_type][0][0], + array($_resource_name, &$params['source_content'], &$this)); + } else { + $_source_return = true; + } + + $_timestamp_return = isset($this->_plugins['resource'][$_resource_type]) && + call_user_func_array($this->_plugins['resource'][$_resource_type][0][1], + array($_resource_name, &$params['resource_timestamp'], &$this)); + + $_return = $_source_return && $_timestamp_return; + break; + } + } + + if (!$_return) { + // see if we can get a template with the default template handler + if (!empty($this->default_template_handler_func)) { + if (!is_callable($this->default_template_handler_func)) { + $this->trigger_error("default template handler function \"$this->default_template_handler_func\" doesn't exist."); + } else { + $_return = call_user_func_array( + $this->default_template_handler_func, + array($_params['resource_type'], $_params['resource_name'], &$params['source_content'], &$params['resource_timestamp'], &$this)); + } + } + } + + if (!$_return) { + if (!$params['quiet']) { + $this->trigger_error('unable to read resource: "' . $params['resource_name'] . '"'); + } + } else if ($_return && $this->security) { + require_once(SMARTY_CORE_DIR . 'core.is_secure.php'); + if (!smarty_core_is_secure($_params, $this)) { + if (!$params['quiet']) + $this->trigger_error('(secure mode) accessing "' . $params['resource_name'] . '" is not allowed'); + $params['source_content'] = null; + $params['resource_timestamp'] = null; + return false; + } + } + return $_return; + } + + + /** + * parse out the type and name from the resource + * + * @param string $resource_base_path + * @param string $resource_name + * @param string $resource_type + * @param string $resource_name + * @return boolean + */ + + function _parse_resource_name(&$params) + { + + // split tpl_path by the first colon + $_resource_name_parts = explode(':', $params['resource_name'], 2); + + if (count($_resource_name_parts) == 1) { + // no resource type given + $params['resource_type'] = $this->default_resource_type; + $params['resource_name'] = $_resource_name_parts[0]; + } else { + if(strlen($_resource_name_parts[0]) == 1) { + // 1 char is not resource type, but part of filepath + $params['resource_type'] = $this->default_resource_type; + $params['resource_name'] = $params['resource_name']; + } else { + $params['resource_type'] = $_resource_name_parts[0]; + $params['resource_name'] = $_resource_name_parts[1]; + } + } + + if ($params['resource_type'] == 'file') { + if (!preg_match('/^([\/\\\\]|[a-zA-Z]:[\/\\\\])/', $params['resource_name'])) { + // relative pathname to $params['resource_base_path'] + // use the first directory where the file is found + foreach ((array)$params['resource_base_path'] as $_curr_path) { + $_fullpath = $_curr_path . DIRECTORY_SEPARATOR . $params['resource_name']; + if (file_exists($_fullpath) && is_file($_fullpath)) { + $params['resource_name'] = $_fullpath; + return true; + } + // didn't find the file, try include_path + $_params = array('file_path' => $_fullpath); + require_once(SMARTY_CORE_DIR . 'core.get_include_path.php'); + if(smarty_core_get_include_path($_params, $this)) { + $params['resource_name'] = $_params['new_file_path']; + return true; + } + } + return false; + } else { + /* absolute path */ + return file_exists($params['resource_name']); + } + } elseif (empty($this->_plugins['resource'][$params['resource_type']])) { + $_params = array('type' => $params['resource_type']); + require_once(SMARTY_CORE_DIR . 'core.load_resource_plugin.php'); + smarty_core_load_resource_plugin($_params, $this); + } + + return true; + } + + + /** + * Handle modifiers + * + * @param string|null $modifier_name + * @param array|null $map_array + * @return string result of modifiers + */ + function _run_mod_handler() + { + $_args = func_get_args(); + list($_modifier_name, $_map_array) = array_splice($_args, 0, 2); + list($_func_name, $_tpl_file, $_tpl_line) = + $this->_plugins['modifier'][$_modifier_name]; + + $_var = $_args[0]; + foreach ($_var as $_key => $_val) { + $_args[0] = $_val; + $_var[$_key] = call_user_func_array($_func_name, $_args); + } + return $_var; + } + + /** + * Remove starting and ending quotes from the string + * + * @param string $string + * @return string + */ + function _dequote($string) + { + if ((substr($string, 0, 1) == "'" || substr($string, 0, 1) == '"') && + substr($string, -1) == substr($string, 0, 1)) + return substr($string, 1, -1); + else + return $string; + } + + + /** + * read in a file + * + * @param string $filename + * @return string + */ + function _read_file($filename) + { + if ( file_exists($filename) && is_readable($filename) && ($fd = @fopen($filename, 'rb')) ) { + $contents = ''; + while (!feof($fd)) { + $contents .= fread($fd, 8192); + } + fclose($fd); + return $contents; + } else { + return false; + } + } + + /** + * get a concrete filename for automagically created content + * + * @param string $auto_base + * @param string $auto_source + * @param string $auto_id + * @return string + * @staticvar string|null + * @staticvar string|null + */ + function _get_auto_filename($auto_base, $auto_source = null, $auto_id = null) + { + $_compile_dir_sep = $this->use_sub_dirs ? DIRECTORY_SEPARATOR : '^'; + $_return = $auto_base . DIRECTORY_SEPARATOR; + + if(isset($auto_id)) { + // make auto_id safe for directory names + $auto_id = str_replace('%7C',$_compile_dir_sep,(urlencode($auto_id))); + // split into separate directories + $_return .= $auto_id . $_compile_dir_sep; + } + + if(isset($auto_source)) { + // make source name safe for filename + $_filename = urlencode(basename($auto_source)); + $_crc32 = sprintf('%08X', crc32($auto_source)); + // prepend %% to avoid name conflicts with + // with $params['auto_id'] names + $_crc32 = substr($_crc32, 0, 2) . $_compile_dir_sep . + substr($_crc32, 0, 3) . $_compile_dir_sep . $_crc32; + $_return .= '%%' . $_crc32 . '%%' . $_filename; + } + + return $_return; + } + + /** + * unlink a file, possibly using expiration time + * + * @param string $resource + * @param integer $exp_time + */ + function _unlink($resource, $exp_time = null) + { + if(isset($exp_time)) { + if(time() - @filemtime($resource) >= $exp_time) { + return @unlink($resource); + } + } else { + return @unlink($resource); + } + } + + /** + * returns an auto_id for auto-file-functions + * + * @param string $cache_id + * @param string $compile_id + * @return string|null + */ + function _get_auto_id($cache_id=null, $compile_id=null) { + if (isset($cache_id)) + return (isset($compile_id)) ? $cache_id . '|' . $compile_id : $cache_id; + elseif(isset($compile_id)) + return $compile_id; + else + return null; + } + + /** + * trigger Smarty plugin error + * + * @param string $error_msg + * @param string $tpl_file + * @param integer $tpl_line + * @param string $file + * @param integer $line + * @param integer $error_type + */ + function _trigger_fatal_error($error_msg, $tpl_file = null, $tpl_line = null, + $file = null, $line = null, $error_type = E_USER_ERROR) + { + if(isset($file) && isset($line)) { + $info = ' ('.basename($file).", line $line)"; + } else { + $info = ''; + } + if (isset($tpl_line) && isset($tpl_file)) { + $this->trigger_error('[in ' . $tpl_file . ' line ' . $tpl_line . "]: $error_msg$info", $error_type); + } else { + $this->trigger_error($error_msg . $info, $error_type); + } + } + + + /** + * callback function for preg_replace, to call a non-cacheable block + * @return string + */ + function _process_compiled_include_callback($match) { + $_func = '_smarty_tplfunc_'.$match[2].'_'.$match[3]; + ob_start(); + $_func($this); + $_ret = ob_get_contents(); + ob_end_clean(); + return $_ret; + } + + + /** + * called for included templates + * + * @param string $_smarty_include_tpl_file + * @param string $_smarty_include_vars + */ + + // $_smarty_include_tpl_file, $_smarty_include_vars + + function _smarty_include($params) + { + if ($this->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $debug_start_time = smarty_core_get_microtime($_params, $this); + $this->_smarty_debug_info[] = array('type' => 'template', + 'filename' => $params['smarty_include_tpl_file'], + 'depth' => ++$this->_inclusion_depth); + $included_tpls_idx = count($this->_smarty_debug_info) - 1; + } + + $this->_tpl_vars = array_merge($this->_tpl_vars, $params['smarty_include_vars']); + + // config vars are treated as local, so push a copy of the + // current ones onto the front of the stack + array_unshift($this->_config, $this->_config[0]); + + $_smarty_compile_path = $this->_get_compile_path($params['smarty_include_tpl_file']); + + + if ($this->_is_compiled($params['smarty_include_tpl_file'], $_smarty_compile_path) + || $this->_compile_resource($params['smarty_include_tpl_file'], $_smarty_compile_path)) + { + include($_smarty_compile_path); + } + + // pop the local vars off the front of the stack + array_shift($this->_config); + + $this->_inclusion_depth--; + + if ($this->debugging) { + // capture time for debugging info + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $this->_smarty_debug_info[$included_tpls_idx]['exec_time'] = smarty_core_get_microtime($_params, $this) - $debug_start_time; + } + + if ($this->caching) { + $this->_cache_info['template'][$params['smarty_include_tpl_file']] = true; + } + } + + + /** + * get or set an array of cached attributes for function that is + * not cacheable + * @return array + */ + function &_smarty_cache_attrs($cache_serial, $count) { + $_cache_attrs =& $this->_cache_info['cache_attrs'][$cache_serial][$count]; + + if ($this->_cache_including) { + /* return next set of cache_attrs */ + $_return = current($_cache_attrs); + next($_cache_attrs); + return $_return; + + } else { + /* add a reference to a new set of cache_attrs */ + $_cache_attrs[] = array(); + return $_cache_attrs[count($_cache_attrs)-1]; + + } + + } + + + /** + * wrapper for include() retaining $this + * @return mixed + */ + function _include($filename, $once=false, $params=null) + { + if ($once) { + return include_once($filename); + } else { + return include($filename); + } + } + + + /** + * wrapper for eval() retaining $this + * @return mixed + */ + function _eval($code, $params=null) + { + return eval($code); + } + + /** + * Extracts the filter name from the given callback + * + * @param callback $function + * @return string + */ + function _get_filter_name($function) + { + if (is_array($function)) { + $_class_name = (is_object($function[0]) ? + get_class($function[0]) : $function[0]); + return $_class_name . '_' . $function[1]; + } + else { + return $function; + } + } + + /**#@-*/ + +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty_Compiler.class.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty_Compiler.class.php new file mode 100644 index 0000000..1178b84 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/Smarty_Compiler.class.php @@ -0,0 +1,2365 @@ + + * @author Andrei Zmievski + * @version 2.6.26 + * @copyright 2001-2005 New Digital Group, Inc. + * @package Smarty + */ + +/* $Id: Smarty_Compiler.class.php 3163 2009-06-17 14:39:24Z monte.ohrt $ */ + +/** + * Template compiling class + * @package Smarty + */ +class Smarty_Compiler extends Smarty { + + // internal vars + /**#@+ + * @access private + */ + var $_folded_blocks = array(); // keeps folded template blocks + var $_current_file = null; // the current template being compiled + var $_current_line_no = 1; // line number for error messages + var $_capture_stack = array(); // keeps track of nested capture buffers + var $_plugin_info = array(); // keeps track of plugins to load + var $_init_smarty_vars = false; + var $_permitted_tokens = array('true','false','yes','no','on','off','null'); + var $_db_qstr_regexp = null; // regexps are setup in the constructor + var $_si_qstr_regexp = null; + var $_qstr_regexp = null; + var $_func_regexp = null; + var $_reg_obj_regexp = null; + var $_var_bracket_regexp = null; + var $_num_const_regexp = null; + var $_dvar_guts_regexp = null; + var $_dvar_regexp = null; + var $_cvar_regexp = null; + var $_svar_regexp = null; + var $_avar_regexp = null; + var $_mod_regexp = null; + var $_var_regexp = null; + var $_parenth_param_regexp = null; + var $_func_call_regexp = null; + var $_obj_ext_regexp = null; + var $_obj_start_regexp = null; + var $_obj_params_regexp = null; + var $_obj_call_regexp = null; + var $_cacheable_state = 0; + var $_cache_attrs_count = 0; + var $_nocache_count = 0; + var $_cache_serial = null; + var $_cache_include = null; + + var $_strip_depth = 0; + var $_additional_newline = "\n"; + + /**#@-*/ + /** + * The class constructor. + */ + function Smarty_Compiler() + { + // matches double quoted strings: + // "foobar" + // "foo\"bar" + $this->_db_qstr_regexp = '"[^"\\\\]*(?:\\\\.[^"\\\\]*)*"'; + + // matches single quoted strings: + // 'foobar' + // 'foo\'bar' + $this->_si_qstr_regexp = '\'[^\'\\\\]*(?:\\\\.[^\'\\\\]*)*\''; + + // matches single or double quoted strings + $this->_qstr_regexp = '(?:' . $this->_db_qstr_regexp . '|' . $this->_si_qstr_regexp . ')'; + + // matches bracket portion of vars + // [0] + // [foo] + // [$bar] + $this->_var_bracket_regexp = '\[\$?[\w\.]+\]'; + + // matches numerical constants + // 30 + // -12 + // 13.22 + $this->_num_const_regexp = '(?:\-?\d+(?:\.\d+)?)'; + + // matches $ vars (not objects): + // $foo + // $foo.bar + // $foo.bar.foobar + // $foo[0] + // $foo[$bar] + // $foo[5][blah] + // $foo[5].bar[$foobar][4] + $this->_dvar_math_regexp = '(?:[\+\*\/\%]|(?:-(?!>)))'; + $this->_dvar_math_var_regexp = '[\$\w\.\+\-\*\/\%\d\>\[\]]'; + $this->_dvar_guts_regexp = '\w+(?:' . $this->_var_bracket_regexp + . ')*(?:\.\$?\w+(?:' . $this->_var_bracket_regexp . ')*)*(?:' . $this->_dvar_math_regexp . '(?:' . $this->_num_const_regexp . '|' . $this->_dvar_math_var_regexp . ')*)?'; + $this->_dvar_regexp = '\$' . $this->_dvar_guts_regexp; + + // matches config vars: + // #foo# + // #foobar123_foo# + $this->_cvar_regexp = '\#\w+\#'; + + // matches section vars: + // %foo.bar% + $this->_svar_regexp = '\%\w+\.\w+\%'; + + // matches all valid variables (no quotes, no modifiers) + $this->_avar_regexp = '(?:' . $this->_dvar_regexp . '|' + . $this->_cvar_regexp . '|' . $this->_svar_regexp . ')'; + + // matches valid variable syntax: + // $foo + // $foo + // #foo# + // #foo# + // "text" + // "text" + $this->_var_regexp = '(?:' . $this->_avar_regexp . '|' . $this->_qstr_regexp . ')'; + + // matches valid object call (one level of object nesting allowed in parameters): + // $foo->bar + // $foo->bar() + // $foo->bar("text") + // $foo->bar($foo, $bar, "text") + // $foo->bar($foo, "foo") + // $foo->bar->foo() + // $foo->bar->foo->bar() + // $foo->bar($foo->bar) + // $foo->bar($foo->bar()) + // $foo->bar($foo->bar($blah,$foo,44,"foo",$foo[0].bar)) + $this->_obj_ext_regexp = '\->(?:\$?' . $this->_dvar_guts_regexp . ')'; + $this->_obj_restricted_param_regexp = '(?:' + . '(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')(?:' . $this->_obj_ext_regexp . '(?:\((?:(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')' + . '(?:\s*,\s*(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . '))*)?\))?)*)'; + $this->_obj_single_param_regexp = '(?:\w+|' . $this->_obj_restricted_param_regexp . '(?:\s*,\s*(?:(?:\w+|' + . $this->_var_regexp . $this->_obj_restricted_param_regexp . ')))*)'; + $this->_obj_params_regexp = '\((?:' . $this->_obj_single_param_regexp + . '(?:\s*,\s*' . $this->_obj_single_param_regexp . ')*)?\)'; + $this->_obj_start_regexp = '(?:' . $this->_dvar_regexp . '(?:' . $this->_obj_ext_regexp . ')+)'; + $this->_obj_call_regexp = '(?:' . $this->_obj_start_regexp . '(?:' . $this->_obj_params_regexp . ')?(?:' . $this->_dvar_math_regexp . '(?:' . $this->_num_const_regexp . '|' . $this->_dvar_math_var_regexp . ')*)?)'; + + // matches valid modifier syntax: + // |foo + // |@foo + // |foo:"bar" + // |foo:$bar + // |foo:"bar":$foobar + // |foo|bar + // |foo:$foo->bar + $this->_mod_regexp = '(?:\|@?\w+(?::(?:\w+|' . $this->_num_const_regexp . '|' + . $this->_obj_call_regexp . '|' . $this->_avar_regexp . '|' . $this->_qstr_regexp .'))*)'; + + // matches valid function name: + // foo123 + // _foo_bar + $this->_func_regexp = '[a-zA-Z_]\w*'; + + // matches valid registered object: + // foo->bar + $this->_reg_obj_regexp = '[a-zA-Z_]\w*->[a-zA-Z_]\w*'; + + // matches valid parameter values: + // true + // $foo + // $foo|bar + // #foo# + // #foo#|bar + // "text" + // "text"|bar + // $foo->bar + $this->_param_regexp = '(?:\s*(?:' . $this->_obj_call_regexp . '|' + . $this->_var_regexp . '|' . $this->_num_const_regexp . '|\w+)(?>' . $this->_mod_regexp . '*)\s*)'; + + // matches valid parenthesised function parameters: + // + // "text" + // $foo, $bar, "text" + // $foo|bar, "foo"|bar, $foo->bar($foo)|bar + $this->_parenth_param_regexp = '(?:\((?:\w+|' + . $this->_param_regexp . '(?:\s*,\s*(?:(?:\w+|' + . $this->_param_regexp . ')))*)?\))'; + + // matches valid function call: + // foo() + // foo_bar($foo) + // _foo_bar($foo,"bar") + // foo123($foo,$foo->bar(),"foo") + $this->_func_call_regexp = '(?:' . $this->_func_regexp . '\s*(?:' + . $this->_parenth_param_regexp . '))'; + } + + /** + * compile a resource + * + * sets $compiled_content to the compiled source + * @param string $resource_name + * @param string $source_content + * @param string $compiled_content + * @return true + */ + function _compile_file($resource_name, $source_content, &$compiled_content) + { + + if ($this->security) { + // do not allow php syntax to be executed unless specified + if ($this->php_handling == SMARTY_PHP_ALLOW && + !$this->security_settings['PHP_HANDLING']) { + $this->php_handling = SMARTY_PHP_PASSTHRU; + } + } + + $this->_load_filters(); + + $this->_current_file = $resource_name; + $this->_current_line_no = 1; + $ldq = preg_quote($this->left_delimiter, '~'); + $rdq = preg_quote($this->right_delimiter, '~'); + + // run template source through prefilter functions + if (count($this->_plugins['prefilter']) > 0) { + foreach ($this->_plugins['prefilter'] as $filter_name => $prefilter) { + if ($prefilter === false) continue; + if ($prefilter[3] || is_callable($prefilter[0])) { + $source_content = call_user_func_array($prefilter[0], + array($source_content, &$this)); + $this->_plugins['prefilter'][$filter_name][3] = true; + } else { + $this->_trigger_fatal_error("[plugin] prefilter '$filter_name' is not implemented"); + } + } + } + + /* fetch all special blocks */ + $search = "~{$ldq}\*(.*?)\*{$rdq}|{$ldq}\s*literal\s*{$rdq}(.*?){$ldq}\s*/literal\s*{$rdq}|{$ldq}\s*php\s*{$rdq}(.*?){$ldq}\s*/php\s*{$rdq}~s"; + + preg_match_all($search, $source_content, $match, PREG_SET_ORDER); + $this->_folded_blocks = $match; + reset($this->_folded_blocks); + + /* replace special blocks by "{php}" */ + $source_content = preg_replace($search.'e', "'" + . $this->_quote_replace($this->left_delimiter) . 'php' + . "' . str_repeat(\"\n\", substr_count('\\0', \"\n\")) .'" + . $this->_quote_replace($this->right_delimiter) + . "'" + , $source_content); + + /* Gather all template tags. */ + preg_match_all("~{$ldq}\s*(.*?)\s*{$rdq}~s", $source_content, $_match); + $template_tags = $_match[1]; + /* Split content by template tags to obtain non-template content. */ + $text_blocks = preg_split("~{$ldq}.*?{$rdq}~s", $source_content); + + /* loop through text blocks */ + for ($curr_tb = 0, $for_max = count($text_blocks); $curr_tb < $for_max; $curr_tb++) { + /* match anything resembling php tags */ + if (preg_match_all('~(<\?(?:\w+|=)?|\?>|language\s*=\s*[\"\']?\s*php\s*[\"\']?)~is', $text_blocks[$curr_tb], $sp_match)) { + /* replace tags with placeholders to prevent recursive replacements */ + $sp_match[1] = array_unique($sp_match[1]); + usort($sp_match[1], '_smarty_sort_length'); + for ($curr_sp = 0, $for_max2 = count($sp_match[1]); $curr_sp < $for_max2; $curr_sp++) { + $text_blocks[$curr_tb] = str_replace($sp_match[1][$curr_sp],'%%%SMARTYSP'.$curr_sp.'%%%',$text_blocks[$curr_tb]); + } + /* process each one */ + for ($curr_sp = 0, $for_max2 = count($sp_match[1]); $curr_sp < $for_max2; $curr_sp++) { + if ($this->php_handling == SMARTY_PHP_PASSTHRU) { + /* echo php contents */ + $text_blocks[$curr_tb] = str_replace('%%%SMARTYSP'.$curr_sp.'%%%', ''."\n", $text_blocks[$curr_tb]); + } else if ($this->php_handling == SMARTY_PHP_QUOTE) { + /* quote php tags */ + $text_blocks[$curr_tb] = str_replace('%%%SMARTYSP'.$curr_sp.'%%%', htmlspecialchars($sp_match[1][$curr_sp]), $text_blocks[$curr_tb]); + } else if ($this->php_handling == SMARTY_PHP_REMOVE) { + /* remove php tags */ + $text_blocks[$curr_tb] = str_replace('%%%SMARTYSP'.$curr_sp.'%%%', '', $text_blocks[$curr_tb]); + } else { + /* SMARTY_PHP_ALLOW, but echo non php starting tags */ + $sp_match[1][$curr_sp] = preg_replace('~(<\?(?!php|=|$))~i', ''."\n", $sp_match[1][$curr_sp]); + $text_blocks[$curr_tb] = str_replace('%%%SMARTYSP'.$curr_sp.'%%%', $sp_match[1][$curr_sp], $text_blocks[$curr_tb]); + } + } + } + } + + /* Compile the template tags into PHP code. */ + $compiled_tags = array(); + for ($i = 0, $for_max = count($template_tags); $i < $for_max; $i++) { + $this->_current_line_no += substr_count($text_blocks[$i], "\n"); + $compiled_tags[] = $this->_compile_tag($template_tags[$i]); + $this->_current_line_no += substr_count($template_tags[$i], "\n"); + } + if (count($this->_tag_stack)>0) { + list($_open_tag, $_line_no) = end($this->_tag_stack); + $this->_syntax_error("unclosed tag \{$_open_tag} (opened line $_line_no).", E_USER_ERROR, __FILE__, __LINE__); + return; + } + + /* Reformat $text_blocks between 'strip' and '/strip' tags, + removing spaces, tabs and newlines. */ + $strip = false; + for ($i = 0, $for_max = count($compiled_tags); $i < $for_max; $i++) { + if ($compiled_tags[$i] == '{strip}') { + $compiled_tags[$i] = ''; + $strip = true; + /* remove leading whitespaces */ + $text_blocks[$i + 1] = ltrim($text_blocks[$i + 1]); + } + if ($strip) { + /* strip all $text_blocks before the next '/strip' */ + for ($j = $i + 1; $j < $for_max; $j++) { + /* remove leading and trailing whitespaces of each line */ + $text_blocks[$j] = preg_replace('![\t ]*[\r\n]+[\t ]*!', '', $text_blocks[$j]); + if ($compiled_tags[$j] == '{/strip}') { + /* remove trailing whitespaces from the last text_block */ + $text_blocks[$j] = rtrim($text_blocks[$j]); + } + $text_blocks[$j] = ""\'", "\\"=>"\\\\")) . "'; ?>"; + if ($compiled_tags[$j] == '{/strip}') { + $compiled_tags[$j] = "\n"; /* slurped by php, but necessary + if a newline is following the closing strip-tag */ + $strip = false; + $i = $j; + break; + } + } + } + } + $compiled_content = ''; + + $tag_guard = '%%%SMARTYOTG' . md5(uniqid(rand(), true)) . '%%%'; + + /* Interleave the compiled contents and text blocks to get the final result. */ + for ($i = 0, $for_max = count($compiled_tags); $i < $for_max; $i++) { + if ($compiled_tags[$i] == '') { + // tag result empty, remove first newline from following text block + $text_blocks[$i+1] = preg_replace('~^(\r\n|\r|\n)~', '', $text_blocks[$i+1]); + } + // replace legit PHP tags with placeholder + $text_blocks[$i] = str_replace('\n", $compiled_content); + $compiled_content = preg_replace("~(?\n", $compiled_content); + + // recover legit tags + $compiled_content = str_replace($tag_guard, '_cache_serial)) { + $compiled_content = "_cache_serials['".$this->_cache_include."'] = '".$this->_cache_serial."'; ?>" . $compiled_content; + } + + // run compiled template through postfilter functions + if (count($this->_plugins['postfilter']) > 0) { + foreach ($this->_plugins['postfilter'] as $filter_name => $postfilter) { + if ($postfilter === false) continue; + if ($postfilter[3] || is_callable($postfilter[0])) { + $compiled_content = call_user_func_array($postfilter[0], + array($compiled_content, &$this)); + $this->_plugins['postfilter'][$filter_name][3] = true; + } else { + $this->_trigger_fatal_error("Smarty plugin error: postfilter '$filter_name' is not implemented"); + } + } + } + + // put header at the top of the compiled template + $template_header = "_version.", created on ".strftime("%Y-%m-%d %H:%M:%S")."\n"; + $template_header .= " compiled from ".strtr(urlencode($resource_name), array('%2F'=>'/', '%3A'=>':'))." */ ?>\n"; + + /* Emit code to load needed plugins. */ + $this->_plugins_code = ''; + if (count($this->_plugin_info)) { + $_plugins_params = "array('plugins' => array("; + foreach ($this->_plugin_info as $plugin_type => $plugins) { + foreach ($plugins as $plugin_name => $plugin_info) { + $_plugins_params .= "array('$plugin_type', '$plugin_name', '" . strtr($plugin_info[0], array("'" => "\\'", "\\" => "\\\\")) . "', $plugin_info[1], "; + $_plugins_params .= $plugin_info[2] ? 'true),' : 'false),'; + } + } + $_plugins_params .= '))'; + $plugins_code = "\n"; + $template_header .= $plugins_code; + $this->_plugin_info = array(); + $this->_plugins_code = $plugins_code; + } + + if ($this->_init_smarty_vars) { + $template_header .= "\n"; + $this->_init_smarty_vars = false; + } + + $compiled_content = $template_header . $compiled_content; + return true; + } + + /** + * Compile a template tag + * + * @param string $template_tag + * @return string + */ + function _compile_tag($template_tag) + { + /* Matched comment. */ + if (substr($template_tag, 0, 1) == '*' && substr($template_tag, -1) == '*') + return ''; + + /* Split tag into two three parts: command, command modifiers and the arguments. */ + if(! preg_match('~^(?:(' . $this->_num_const_regexp . '|' . $this->_obj_call_regexp . '|' . $this->_var_regexp + . '|\/?' . $this->_reg_obj_regexp . '|\/?' . $this->_func_regexp . ')(' . $this->_mod_regexp . '*)) + (?:\s+(.*))?$ + ~xs', $template_tag, $match)) { + $this->_syntax_error("unrecognized tag: $template_tag", E_USER_ERROR, __FILE__, __LINE__); + } + + $tag_command = $match[1]; + $tag_modifier = isset($match[2]) ? $match[2] : null; + $tag_args = isset($match[3]) ? $match[3] : null; + + if (preg_match('~^' . $this->_num_const_regexp . '|' . $this->_obj_call_regexp . '|' . $this->_var_regexp . '$~', $tag_command)) { + /* tag name is a variable or object */ + $_return = $this->_parse_var_props($tag_command . $tag_modifier); + return "" . $this->_additional_newline; + } + + /* If the tag name is a registered object, we process it. */ + if (preg_match('~^\/?' . $this->_reg_obj_regexp . '$~', $tag_command)) { + return $this->_compile_registered_object_tag($tag_command, $this->_parse_attrs($tag_args), $tag_modifier); + } + + switch ($tag_command) { + case 'include': + return $this->_compile_include_tag($tag_args); + + case 'include_php': + return $this->_compile_include_php_tag($tag_args); + + case 'if': + $this->_push_tag('if'); + return $this->_compile_if_tag($tag_args); + + case 'else': + list($_open_tag) = end($this->_tag_stack); + if ($_open_tag != 'if' && $_open_tag != 'elseif') + $this->_syntax_error('unexpected {else}', E_USER_ERROR, __FILE__, __LINE__); + else + $this->_push_tag('else'); + return ''; + + case 'elseif': + list($_open_tag) = end($this->_tag_stack); + if ($_open_tag != 'if' && $_open_tag != 'elseif') + $this->_syntax_error('unexpected {elseif}', E_USER_ERROR, __FILE__, __LINE__); + if ($_open_tag == 'if') + $this->_push_tag('elseif'); + return $this->_compile_if_tag($tag_args, true); + + case '/if': + $this->_pop_tag('if'); + return ''; + + case 'capture': + return $this->_compile_capture_tag(true, $tag_args); + + case '/capture': + return $this->_compile_capture_tag(false); + + case 'ldelim': + return $this->left_delimiter; + + case 'rdelim': + return $this->right_delimiter; + + case 'section': + $this->_push_tag('section'); + return $this->_compile_section_start($tag_args); + + case 'sectionelse': + $this->_push_tag('sectionelse'); + return ""; + break; + + case '/section': + $_open_tag = $this->_pop_tag('section'); + if ($_open_tag == 'sectionelse') + return ""; + else + return ""; + + case 'foreach': + $this->_push_tag('foreach'); + return $this->_compile_foreach_start($tag_args); + break; + + case 'foreachelse': + $this->_push_tag('foreachelse'); + return ""; + + case '/foreach': + $_open_tag = $this->_pop_tag('foreach'); + if ($_open_tag == 'foreachelse') + return ""; + else + return ""; + break; + + case 'strip': + case '/strip': + if (substr($tag_command, 0, 1)=='/') { + $this->_pop_tag('strip'); + if (--$this->_strip_depth==0) { /* outermost closing {/strip} */ + $this->_additional_newline = "\n"; + return '{' . $tag_command . '}'; + } + } else { + $this->_push_tag('strip'); + if ($this->_strip_depth++==0) { /* outermost opening {strip} */ + $this->_additional_newline = ""; + return '{' . $tag_command . '}'; + } + } + return ''; + + case 'php': + /* handle folded tags replaced by {php} */ + list(, $block) = each($this->_folded_blocks); + $this->_current_line_no += substr_count($block[0], "\n"); + /* the number of matched elements in the regexp in _compile_file() + determins the type of folded tag that was found */ + switch (count($block)) { + case 2: /* comment */ + return ''; + + case 3: /* literal */ + return ""\'", "\\"=>"\\\\")) . "'; ?>" . $this->_additional_newline; + + case 4: /* php */ + if ($this->security && !$this->security_settings['PHP_TAGS']) { + $this->_syntax_error("(secure mode) php tags not permitted", E_USER_WARNING, __FILE__, __LINE__); + return; + } + return ''; + } + break; + + case 'insert': + return $this->_compile_insert_tag($tag_args); + + default: + if ($this->_compile_compiler_tag($tag_command, $tag_args, $output)) { + return $output; + } else if ($this->_compile_block_tag($tag_command, $tag_args, $tag_modifier, $output)) { + return $output; + } else if ($this->_compile_custom_tag($tag_command, $tag_args, $tag_modifier, $output)) { + return $output; + } else { + $this->_syntax_error("unrecognized tag '$tag_command'", E_USER_ERROR, __FILE__, __LINE__); + } + + } + } + + + /** + * compile the custom compiler tag + * + * sets $output to the compiled custom compiler tag + * @param string $tag_command + * @param string $tag_args + * @param string $output + * @return boolean + */ + function _compile_compiler_tag($tag_command, $tag_args, &$output) + { + $found = false; + $have_function = true; + + /* + * First we check if the compiler function has already been registered + * or loaded from a plugin file. + */ + if (isset($this->_plugins['compiler'][$tag_command])) { + $found = true; + $plugin_func = $this->_plugins['compiler'][$tag_command][0]; + if (!is_callable($plugin_func)) { + $message = "compiler function '$tag_command' is not implemented"; + $have_function = false; + } + } + /* + * Otherwise we need to load plugin file and look for the function + * inside it. + */ + else if ($plugin_file = $this->_get_plugin_filepath('compiler', $tag_command)) { + $found = true; + + include_once $plugin_file; + + $plugin_func = 'smarty_compiler_' . $tag_command; + if (!is_callable($plugin_func)) { + $message = "plugin function $plugin_func() not found in $plugin_file\n"; + $have_function = false; + } else { + $this->_plugins['compiler'][$tag_command] = array($plugin_func, null, null, null, true); + } + } + + /* + * True return value means that we either found a plugin or a + * dynamically registered function. False means that we didn't and the + * compiler should now emit code to load custom function plugin for this + * tag. + */ + if ($found) { + if ($have_function) { + $output = call_user_func_array($plugin_func, array($tag_args, &$this)); + if($output != '') { + $output = '_push_cacheable_state('compiler', $tag_command) + . $output + . $this->_pop_cacheable_state('compiler', $tag_command) . ' ?>'; + } + } else { + $this->_syntax_error($message, E_USER_WARNING, __FILE__, __LINE__); + } + return true; + } else { + return false; + } + } + + + /** + * compile block function tag + * + * sets $output to compiled block function tag + * @param string $tag_command + * @param string $tag_args + * @param string $tag_modifier + * @param string $output + * @return boolean + */ + function _compile_block_tag($tag_command, $tag_args, $tag_modifier, &$output) + { + if (substr($tag_command, 0, 1) == '/') { + $start_tag = false; + $tag_command = substr($tag_command, 1); + } else + $start_tag = true; + + $found = false; + $have_function = true; + + /* + * First we check if the block function has already been registered + * or loaded from a plugin file. + */ + if (isset($this->_plugins['block'][$tag_command])) { + $found = true; + $plugin_func = $this->_plugins['block'][$tag_command][0]; + if (!is_callable($plugin_func)) { + $message = "block function '$tag_command' is not implemented"; + $have_function = false; + } + } + /* + * Otherwise we need to load plugin file and look for the function + * inside it. + */ + else if ($plugin_file = $this->_get_plugin_filepath('block', $tag_command)) { + $found = true; + + include_once $plugin_file; + + $plugin_func = 'smarty_block_' . $tag_command; + if (!function_exists($plugin_func)) { + $message = "plugin function $plugin_func() not found in $plugin_file\n"; + $have_function = false; + } else { + $this->_plugins['block'][$tag_command] = array($plugin_func, null, null, null, true); + + } + } + + if (!$found) { + return false; + } else if (!$have_function) { + $this->_syntax_error($message, E_USER_WARNING, __FILE__, __LINE__); + return true; + } + + /* + * Even though we've located the plugin function, compilation + * happens only once, so the plugin will still need to be loaded + * at runtime for future requests. + */ + $this->_add_plugin('block', $tag_command); + + if ($start_tag) + $this->_push_tag($tag_command); + else + $this->_pop_tag($tag_command); + + if ($start_tag) { + $output = '_push_cacheable_state('block', $tag_command); + $attrs = $this->_parse_attrs($tag_args); + $_cache_attrs=''; + $arg_list = $this->_compile_arg_list('block', $tag_command, $attrs, $_cache_attrs); + $output .= "$_cache_attrs\$this->_tag_stack[] = array('$tag_command', array(".implode(',', $arg_list).')); '; + $output .= '$_block_repeat=true;' . $this->_compile_plugin_call('block', $tag_command).'($this->_tag_stack[count($this->_tag_stack)-1][1], null, $this, $_block_repeat);'; + $output .= 'while ($_block_repeat) { ob_start(); ?>'; + } else { + $output = '_compile_plugin_call('block', $tag_command).'($this->_tag_stack[count($this->_tag_stack)-1][1], $_block_content, $this, $_block_repeat)'; + if ($tag_modifier != '') { + $this->_parse_modifiers($_out_tag_text, $tag_modifier); + } + $output .= '$_block_repeat=false;echo ' . $_out_tag_text . '; } '; + $output .= " array_pop(\$this->_tag_stack); " . $this->_pop_cacheable_state('block', $tag_command) . '?>'; + } + + return true; + } + + + /** + * compile custom function tag + * + * @param string $tag_command + * @param string $tag_args + * @param string $tag_modifier + * @return string + */ + function _compile_custom_tag($tag_command, $tag_args, $tag_modifier, &$output) + { + $found = false; + $have_function = true; + + /* + * First we check if the custom function has already been registered + * or loaded from a plugin file. + */ + if (isset($this->_plugins['function'][$tag_command])) { + $found = true; + $plugin_func = $this->_plugins['function'][$tag_command][0]; + if (!is_callable($plugin_func)) { + $message = "custom function '$tag_command' is not implemented"; + $have_function = false; + } + } + /* + * Otherwise we need to load plugin file and look for the function + * inside it. + */ + else if ($plugin_file = $this->_get_plugin_filepath('function', $tag_command)) { + $found = true; + + include_once $plugin_file; + + $plugin_func = 'smarty_function_' . $tag_command; + if (!function_exists($plugin_func)) { + $message = "plugin function $plugin_func() not found in $plugin_file\n"; + $have_function = false; + } else { + $this->_plugins['function'][$tag_command] = array($plugin_func, null, null, null, true); + + } + } + + if (!$found) { + return false; + } else if (!$have_function) { + $this->_syntax_error($message, E_USER_WARNING, __FILE__, __LINE__); + return true; + } + + /* declare plugin to be loaded on display of the template that + we compile right now */ + $this->_add_plugin('function', $tag_command); + + $_cacheable_state = $this->_push_cacheable_state('function', $tag_command); + $attrs = $this->_parse_attrs($tag_args); + $_cache_attrs = ''; + $arg_list = $this->_compile_arg_list('function', $tag_command, $attrs, $_cache_attrs); + + $output = $this->_compile_plugin_call('function', $tag_command).'(array('.implode(',', $arg_list)."), \$this)"; + if($tag_modifier != '') { + $this->_parse_modifiers($output, $tag_modifier); + } + + if($output != '') { + $output = '_pop_cacheable_state('function', $tag_command) . "?>" . $this->_additional_newline; + } + + return true; + } + + /** + * compile a registered object tag + * + * @param string $tag_command + * @param array $attrs + * @param string $tag_modifier + * @return string + */ + function _compile_registered_object_tag($tag_command, $attrs, $tag_modifier) + { + if (substr($tag_command, 0, 1) == '/') { + $start_tag = false; + $tag_command = substr($tag_command, 1); + } else { + $start_tag = true; + } + + list($object, $obj_comp) = explode('->', $tag_command); + + $arg_list = array(); + if(count($attrs)) { + $_assign_var = false; + foreach ($attrs as $arg_name => $arg_value) { + if($arg_name == 'assign') { + $_assign_var = $arg_value; + unset($attrs['assign']); + continue; + } + if (is_bool($arg_value)) + $arg_value = $arg_value ? 'true' : 'false'; + $arg_list[] = "'$arg_name' => $arg_value"; + } + } + + if($this->_reg_objects[$object][2]) { + // smarty object argument format + $args = "array(".implode(',', (array)$arg_list)."), \$this"; + } else { + // traditional argument format + $args = implode(',', array_values($attrs)); + if (empty($args)) { + $args = ''; + } + } + + $prefix = ''; + $postfix = ''; + $newline = ''; + if(!is_object($this->_reg_objects[$object][0])) { + $this->_trigger_fatal_error("registered '$object' is not an object" , $this->_current_file, $this->_current_line_no, __FILE__, __LINE__); + } elseif(!empty($this->_reg_objects[$object][1]) && !in_array($obj_comp, $this->_reg_objects[$object][1])) { + $this->_trigger_fatal_error("'$obj_comp' is not a registered component of object '$object'", $this->_current_file, $this->_current_line_no, __FILE__, __LINE__); + } elseif(method_exists($this->_reg_objects[$object][0], $obj_comp)) { + // method + if(in_array($obj_comp, $this->_reg_objects[$object][3])) { + // block method + if ($start_tag) { + $prefix = "\$this->_tag_stack[] = array('$obj_comp', $args); "; + $prefix .= "\$_block_repeat=true; \$this->_reg_objects['$object'][0]->$obj_comp(\$this->_tag_stack[count(\$this->_tag_stack)-1][1], null, \$this, \$_block_repeat); "; + $prefix .= "while (\$_block_repeat) { ob_start();"; + $return = null; + $postfix = ''; + } else { + $prefix = "\$_obj_block_content = ob_get_contents(); ob_end_clean(); \$_block_repeat=false;"; + $return = "\$this->_reg_objects['$object'][0]->$obj_comp(\$this->_tag_stack[count(\$this->_tag_stack)-1][1], \$_obj_block_content, \$this, \$_block_repeat)"; + $postfix = "} array_pop(\$this->_tag_stack);"; + } + } else { + // non-block method + $return = "\$this->_reg_objects['$object'][0]->$obj_comp($args)"; + } + } else { + // property + $return = "\$this->_reg_objects['$object'][0]->$obj_comp"; + } + + if($return != null) { + if($tag_modifier != '') { + $this->_parse_modifiers($return, $tag_modifier); + } + + if(!empty($_assign_var)) { + $output = "\$this->assign('" . $this->_dequote($_assign_var) ."', $return);"; + } else { + $output = 'echo ' . $return . ';'; + $newline = $this->_additional_newline; + } + } else { + $output = ''; + } + + return '" . $newline; + } + + /** + * Compile {insert ...} tag + * + * @param string $tag_args + * @return string + */ + function _compile_insert_tag($tag_args) + { + $attrs = $this->_parse_attrs($tag_args); + $name = $this->_dequote($attrs['name']); + + if (empty($name)) { + return $this->_syntax_error("missing insert name", E_USER_ERROR, __FILE__, __LINE__); + } + + if (!preg_match('~^\w+$~', $name)) { + return $this->_syntax_error("'insert: 'name' must be an insert function name", E_USER_ERROR, __FILE__, __LINE__); + } + + if (!empty($attrs['script'])) { + $delayed_loading = true; + } else { + $delayed_loading = false; + } + + foreach ($attrs as $arg_name => $arg_value) { + if (is_bool($arg_value)) + $arg_value = $arg_value ? 'true' : 'false'; + $arg_list[] = "'$arg_name' => $arg_value"; + } + + $this->_add_plugin('insert', $name, $delayed_loading); + + $_params = "array('args' => array(".implode(', ', (array)$arg_list)."))"; + + return "" . $this->_additional_newline; + } + + /** + * Compile {include ...} tag + * + * @param string $tag_args + * @return string + */ + function _compile_include_tag($tag_args) + { + $attrs = $this->_parse_attrs($tag_args); + $arg_list = array(); + + if (empty($attrs['file'])) { + $this->_syntax_error("missing 'file' attribute in include tag", E_USER_ERROR, __FILE__, __LINE__); + } + + foreach ($attrs as $arg_name => $arg_value) { + if ($arg_name == 'file') { + $include_file = $arg_value; + continue; + } else if ($arg_name == 'assign') { + $assign_var = $arg_value; + continue; + } + if (is_bool($arg_value)) + $arg_value = $arg_value ? 'true' : 'false'; + $arg_list[] = "'$arg_name' => $arg_value"; + } + + $output = '_tpl_vars;\n"; + + + $_params = "array('smarty_include_tpl_file' => " . $include_file . ", 'smarty_include_vars' => array(".implode(',', (array)$arg_list)."))"; + $output .= "\$this->_smarty_include($_params);\n" . + "\$this->_tpl_vars = \$_smarty_tpl_vars;\n" . + "unset(\$_smarty_tpl_vars);\n"; + + if (isset($assign_var)) { + $output .= "\$this->assign(" . $assign_var . ", ob_get_contents()); ob_end_clean();\n"; + } + + $output .= ' ?>'; + + return $output; + + } + + /** + * Compile {include ...} tag + * + * @param string $tag_args + * @return string + */ + function _compile_include_php_tag($tag_args) + { + $attrs = $this->_parse_attrs($tag_args); + + if (empty($attrs['file'])) { + $this->_syntax_error("missing 'file' attribute in include_php tag", E_USER_ERROR, __FILE__, __LINE__); + } + + $assign_var = (empty($attrs['assign'])) ? '' : $this->_dequote($attrs['assign']); + $once_var = (empty($attrs['once']) || $attrs['once']=='false') ? 'false' : 'true'; + + $arg_list = array(); + foreach($attrs as $arg_name => $arg_value) { + if($arg_name != 'file' AND $arg_name != 'once' AND $arg_name != 'assign') { + if(is_bool($arg_value)) + $arg_value = $arg_value ? 'true' : 'false'; + $arg_list[] = "'$arg_name' => $arg_value"; + } + } + + $_params = "array('smarty_file' => " . $attrs['file'] . ", 'smarty_assign' => '$assign_var', 'smarty_once' => $once_var, 'smarty_include_vars' => array(".implode(',', $arg_list)."))"; + + return "" . $this->_additional_newline; + } + + + /** + * Compile {section ...} tag + * + * @param string $tag_args + * @return string + */ + function _compile_section_start($tag_args) + { + $attrs = $this->_parse_attrs($tag_args); + $arg_list = array(); + + $output = '_syntax_error("missing section name", E_USER_ERROR, __FILE__, __LINE__); + } + + $output .= "unset(\$this->_sections[$section_name]);\n"; + $section_props = "\$this->_sections[$section_name]"; + + foreach ($attrs as $attr_name => $attr_value) { + switch ($attr_name) { + case 'loop': + $output .= "{$section_props}['loop'] = is_array(\$_loop=$attr_value) ? count(\$_loop) : max(0, (int)\$_loop); unset(\$_loop);\n"; + break; + + case 'show': + if (is_bool($attr_value)) + $show_attr_value = $attr_value ? 'true' : 'false'; + else + $show_attr_value = "(bool)$attr_value"; + $output .= "{$section_props}['show'] = $show_attr_value;\n"; + break; + + case 'name': + $output .= "{$section_props}['$attr_name'] = $attr_value;\n"; + break; + + case 'max': + case 'start': + $output .= "{$section_props}['$attr_name'] = (int)$attr_value;\n"; + break; + + case 'step': + $output .= "{$section_props}['$attr_name'] = ((int)$attr_value) == 0 ? 1 : (int)$attr_value;\n"; + break; + + default: + $this->_syntax_error("unknown section attribute - '$attr_name'", E_USER_ERROR, __FILE__, __LINE__); + break; + } + } + + if (!isset($attrs['show'])) + $output .= "{$section_props}['show'] = true;\n"; + + if (!isset($attrs['loop'])) + $output .= "{$section_props}['loop'] = 1;\n"; + + if (!isset($attrs['max'])) + $output .= "{$section_props}['max'] = {$section_props}['loop'];\n"; + else + $output .= "if ({$section_props}['max'] < 0)\n" . + " {$section_props}['max'] = {$section_props}['loop'];\n"; + + if (!isset($attrs['step'])) + $output .= "{$section_props}['step'] = 1;\n"; + + if (!isset($attrs['start'])) + $output .= "{$section_props}['start'] = {$section_props}['step'] > 0 ? 0 : {$section_props}['loop']-1;\n"; + else { + $output .= "if ({$section_props}['start'] < 0)\n" . + " {$section_props}['start'] = max({$section_props}['step'] > 0 ? 0 : -1, {$section_props}['loop'] + {$section_props}['start']);\n" . + "else\n" . + " {$section_props}['start'] = min({$section_props}['start'], {$section_props}['step'] > 0 ? {$section_props}['loop'] : {$section_props}['loop']-1);\n"; + } + + $output .= "if ({$section_props}['show']) {\n"; + if (!isset($attrs['start']) && !isset($attrs['step']) && !isset($attrs['max'])) { + $output .= " {$section_props}['total'] = {$section_props}['loop'];\n"; + } else { + $output .= " {$section_props}['total'] = min(ceil(({$section_props}['step'] > 0 ? {$section_props}['loop'] - {$section_props}['start'] : {$section_props}['start']+1)/abs({$section_props}['step'])), {$section_props}['max']);\n"; + } + $output .= " if ({$section_props}['total'] == 0)\n" . + " {$section_props}['show'] = false;\n" . + "} else\n" . + " {$section_props}['total'] = 0;\n"; + + $output .= "if ({$section_props}['show']):\n"; + $output .= " + for ({$section_props}['index'] = {$section_props}['start'], {$section_props}['iteration'] = 1; + {$section_props}['iteration'] <= {$section_props}['total']; + {$section_props}['index'] += {$section_props}['step'], {$section_props}['iteration']++):\n"; + $output .= "{$section_props}['rownum'] = {$section_props}['iteration'];\n"; + $output .= "{$section_props}['index_prev'] = {$section_props}['index'] - {$section_props}['step'];\n"; + $output .= "{$section_props}['index_next'] = {$section_props}['index'] + {$section_props}['step'];\n"; + $output .= "{$section_props}['first'] = ({$section_props}['iteration'] == 1);\n"; + $output .= "{$section_props}['last'] = ({$section_props}['iteration'] == {$section_props}['total']);\n"; + + $output .= "?>"; + + return $output; + } + + + /** + * Compile {foreach ...} tag. + * + * @param string $tag_args + * @return string + */ + function _compile_foreach_start($tag_args) + { + $attrs = $this->_parse_attrs($tag_args); + $arg_list = array(); + + if (empty($attrs['from'])) { + return $this->_syntax_error("foreach: missing 'from' attribute", E_USER_ERROR, __FILE__, __LINE__); + } + $from = $attrs['from']; + + if (empty($attrs['item'])) { + return $this->_syntax_error("foreach: missing 'item' attribute", E_USER_ERROR, __FILE__, __LINE__); + } + $item = $this->_dequote($attrs['item']); + if (!preg_match('~^\w+$~', $item)) { + return $this->_syntax_error("foreach: 'item' must be a variable name (literal string)", E_USER_ERROR, __FILE__, __LINE__); + } + + if (isset($attrs['key'])) { + $key = $this->_dequote($attrs['key']); + if (!preg_match('~^\w+$~', $key)) { + return $this->_syntax_error("foreach: 'key' must to be a variable name (literal string)", E_USER_ERROR, __FILE__, __LINE__); + } + $key_part = "\$this->_tpl_vars['$key'] => "; + } else { + $key = null; + $key_part = ''; + } + + if (isset($attrs['name'])) { + $name = $attrs['name']; + } else { + $name = null; + } + + $output = '_foreach[$name]"; + $output .= "{$foreach_props} = array('total' => count(\$_from), 'iteration' => 0);\n"; + $output .= "if ({$foreach_props}['total'] > 0):\n"; + $output .= " foreach (\$_from as $key_part\$this->_tpl_vars['$item']):\n"; + $output .= " {$foreach_props}['iteration']++;\n"; + } else { + $output .= "if (count(\$_from)):\n"; + $output .= " foreach (\$_from as $key_part\$this->_tpl_vars['$item']):\n"; + } + $output .= '?>'; + + return $output; + } + + + /** + * Compile {capture} .. {/capture} tags + * + * @param boolean $start true if this is the {capture} tag + * @param string $tag_args + * @return string + */ + + function _compile_capture_tag($start, $tag_args = '') + { + $attrs = $this->_parse_attrs($tag_args); + + if ($start) { + $buffer = isset($attrs['name']) ? $attrs['name'] : "'default'"; + $assign = isset($attrs['assign']) ? $attrs['assign'] : null; + $append = isset($attrs['append']) ? $attrs['append'] : null; + + $output = ""; + $this->_capture_stack[] = array($buffer, $assign, $append); + } else { + list($buffer, $assign, $append) = array_pop($this->_capture_stack); + $output = "_smarty_vars['capture'][$buffer] = ob_get_contents(); "; + if (isset($assign)) { + $output .= " \$this->assign($assign, ob_get_contents());"; + } + if (isset($append)) { + $output .= " \$this->append($append, ob_get_contents());"; + } + $output .= "ob_end_clean(); ?>"; + } + + return $output; + } + + /** + * Compile {if ...} tag + * + * @param string $tag_args + * @param boolean $elseif if true, uses elseif instead of if + * @return string + */ + function _compile_if_tag($tag_args, $elseif = false) + { + + /* Tokenize args for 'if' tag. */ + preg_match_all('~(?> + ' . $this->_obj_call_regexp . '(?:' . $this->_mod_regexp . '*)? | # valid object call + ' . $this->_var_regexp . '(?:' . $this->_mod_regexp . '*)? | # var or quoted string + \-?0[xX][0-9a-fA-F]+|\-?\d+(?:\.\d+)?|\.\d+|!==|===|==|!=|<>|<<|>>|<=|>=|\&\&|\|\||\(|\)|,|\!|\^|=|\&|\~|<|>|\||\%|\+|\-|\/|\*|\@ | # valid non-word token + \b\w+\b | # valid word token + \S+ # anything else + )~x', $tag_args, $match); + + $tokens = $match[0]; + + if(empty($tokens)) { + $_error_msg = $elseif ? "'elseif'" : "'if'"; + $_error_msg .= ' statement requires arguments'; + $this->_syntax_error($_error_msg, E_USER_ERROR, __FILE__, __LINE__); + } + + + // make sure we have balanced parenthesis + $token_count = array_count_values($tokens); + if(isset($token_count['(']) && $token_count['('] != $token_count[')']) { + $this->_syntax_error("unbalanced parenthesis in if statement", E_USER_ERROR, __FILE__, __LINE__); + } + + $is_arg_stack = array(); + + for ($i = 0; $i < count($tokens); $i++) { + + $token = &$tokens[$i]; + + switch (strtolower($token)) { + case '!': + case '%': + case '!==': + case '==': + case '===': + case '>': + case '<': + case '!=': + case '<>': + case '<<': + case '>>': + case '<=': + case '>=': + case '&&': + case '||': + case '|': + case '^': + case '&': + case '~': + case ')': + case ',': + case '+': + case '-': + case '*': + case '/': + case '@': + break; + + case 'eq': + $token = '=='; + break; + + case 'ne': + case 'neq': + $token = '!='; + break; + + case 'lt': + $token = '<'; + break; + + case 'le': + case 'lte': + $token = '<='; + break; + + case 'gt': + $token = '>'; + break; + + case 'ge': + case 'gte': + $token = '>='; + break; + + case 'and': + $token = '&&'; + break; + + case 'or': + $token = '||'; + break; + + case 'not': + $token = '!'; + break; + + case 'mod': + $token = '%'; + break; + + case '(': + array_push($is_arg_stack, $i); + break; + + case 'is': + /* If last token was a ')', we operate on the parenthesized + expression. The start of the expression is on the stack. + Otherwise, we operate on the last encountered token. */ + if ($tokens[$i-1] == ')') { + $is_arg_start = array_pop($is_arg_stack); + if ($is_arg_start != 0) { + if (preg_match('~^' . $this->_func_regexp . '$~', $tokens[$is_arg_start-1])) { + $is_arg_start--; + } + } + } else + $is_arg_start = $i-1; + /* Construct the argument for 'is' expression, so it knows + what to operate on. */ + $is_arg = implode(' ', array_slice($tokens, $is_arg_start, $i - $is_arg_start)); + + /* Pass all tokens from next one until the end to the + 'is' expression parsing function. The function will + return modified tokens, where the first one is the result + of the 'is' expression and the rest are the tokens it + didn't touch. */ + $new_tokens = $this->_parse_is_expr($is_arg, array_slice($tokens, $i+1)); + + /* Replace the old tokens with the new ones. */ + array_splice($tokens, $is_arg_start, count($tokens), $new_tokens); + + /* Adjust argument start so that it won't change from the + current position for the next iteration. */ + $i = $is_arg_start; + break; + + default: + if(preg_match('~^' . $this->_func_regexp . '$~', $token) ) { + // function call + if($this->security && + !in_array($token, $this->security_settings['IF_FUNCS'])) { + $this->_syntax_error("(secure mode) '$token' not allowed in if statement", E_USER_ERROR, __FILE__, __LINE__); + } + } elseif(preg_match('~^' . $this->_var_regexp . '$~', $token) && (strpos('+-*/^%&|', substr($token, -1)) === false) && isset($tokens[$i+1]) && $tokens[$i+1] == '(') { + // variable function call + $this->_syntax_error("variable function call '$token' not allowed in if statement", E_USER_ERROR, __FILE__, __LINE__); + } elseif(preg_match('~^' . $this->_obj_call_regexp . '|' . $this->_var_regexp . '(?:' . $this->_mod_regexp . '*)$~', $token)) { + // object or variable + $token = $this->_parse_var_props($token); + } elseif(is_numeric($token)) { + // number, skip it + } else { + $this->_syntax_error("unidentified token '$token'", E_USER_ERROR, __FILE__, __LINE__); + } + break; + } + } + + if ($elseif) + return ''; + else + return ''; + } + + + function _compile_arg_list($type, $name, $attrs, &$cache_code) { + $arg_list = array(); + + if (isset($type) && isset($name) + && isset($this->_plugins[$type]) + && isset($this->_plugins[$type][$name]) + && empty($this->_plugins[$type][$name][4]) + && is_array($this->_plugins[$type][$name][5]) + ) { + /* we have a list of parameters that should be cached */ + $_cache_attrs = $this->_plugins[$type][$name][5]; + $_count = $this->_cache_attrs_count++; + $cache_code = "\$_cache_attrs =& \$this->_smarty_cache_attrs('$this->_cache_serial','$_count');"; + + } else { + /* no parameters are cached */ + $_cache_attrs = null; + } + + foreach ($attrs as $arg_name => $arg_value) { + if (is_bool($arg_value)) + $arg_value = $arg_value ? 'true' : 'false'; + if (is_null($arg_value)) + $arg_value = 'null'; + if ($_cache_attrs && in_array($arg_name, $_cache_attrs)) { + $arg_list[] = "'$arg_name' => (\$this->_cache_including) ? \$_cache_attrs['$arg_name'] : (\$_cache_attrs['$arg_name']=$arg_value)"; + } else { + $arg_list[] = "'$arg_name' => $arg_value"; + } + } + return $arg_list; + } + + /** + * Parse is expression + * + * @param string $is_arg + * @param array $tokens + * @return array + */ + function _parse_is_expr($is_arg, $tokens) + { + $expr_end = 0; + $negate_expr = false; + + if (($first_token = array_shift($tokens)) == 'not') { + $negate_expr = true; + $expr_type = array_shift($tokens); + } else + $expr_type = $first_token; + + switch ($expr_type) { + case 'even': + if (isset($tokens[$expr_end]) && $tokens[$expr_end] == 'by') { + $expr_end++; + $expr_arg = $tokens[$expr_end++]; + $expr = "!(1 & ($is_arg / " . $this->_parse_var_props($expr_arg) . "))"; + } else + $expr = "!(1 & $is_arg)"; + break; + + case 'odd': + if (isset($tokens[$expr_end]) && $tokens[$expr_end] == 'by') { + $expr_end++; + $expr_arg = $tokens[$expr_end++]; + $expr = "(1 & ($is_arg / " . $this->_parse_var_props($expr_arg) . "))"; + } else + $expr = "(1 & $is_arg)"; + break; + + case 'div': + if (@$tokens[$expr_end] == 'by') { + $expr_end++; + $expr_arg = $tokens[$expr_end++]; + $expr = "!($is_arg % " . $this->_parse_var_props($expr_arg) . ")"; + } else { + $this->_syntax_error("expecting 'by' after 'div'", E_USER_ERROR, __FILE__, __LINE__); + } + break; + + default: + $this->_syntax_error("unknown 'is' expression - '$expr_type'", E_USER_ERROR, __FILE__, __LINE__); + break; + } + + if ($negate_expr) { + $expr = "!($expr)"; + } + + array_splice($tokens, 0, $expr_end, $expr); + + return $tokens; + } + + + /** + * Parse attribute string + * + * @param string $tag_args + * @return array + */ + function _parse_attrs($tag_args) + { + + /* Tokenize tag attributes. */ + preg_match_all('~(?:' . $this->_obj_call_regexp . '|' . $this->_qstr_regexp . ' | (?>[^"\'=\s]+) + )+ | + [=] + ~x', $tag_args, $match); + $tokens = $match[0]; + + $attrs = array(); + /* Parse state: + 0 - expecting attribute name + 1 - expecting '=' + 2 - expecting attribute value (not '=') */ + $state = 0; + + foreach ($tokens as $token) { + switch ($state) { + case 0: + /* If the token is a valid identifier, we set attribute name + and go to state 1. */ + if (preg_match('~^\w+$~', $token)) { + $attr_name = $token; + $state = 1; + } else + $this->_syntax_error("invalid attribute name: '$token'", E_USER_ERROR, __FILE__, __LINE__); + break; + + case 1: + /* If the token is '=', then we go to state 2. */ + if ($token == '=') { + $state = 2; + } else + $this->_syntax_error("expecting '=' after attribute name '$last_token'", E_USER_ERROR, __FILE__, __LINE__); + break; + + case 2: + /* If token is not '=', we set the attribute value and go to + state 0. */ + if ($token != '=') { + /* We booleanize the token if it's a non-quoted possible + boolean value. */ + if (preg_match('~^(on|yes|true)$~', $token)) { + $token = 'true'; + } else if (preg_match('~^(off|no|false)$~', $token)) { + $token = 'false'; + } else if ($token == 'null') { + $token = 'null'; + } else if (preg_match('~^' . $this->_num_const_regexp . '|0[xX][0-9a-fA-F]+$~', $token)) { + /* treat integer literally */ + } else if (!preg_match('~^' . $this->_obj_call_regexp . '|' . $this->_var_regexp . '(?:' . $this->_mod_regexp . ')*$~', $token)) { + /* treat as a string, double-quote it escaping quotes */ + $token = '"'.addslashes($token).'"'; + } + + $attrs[$attr_name] = $token; + $state = 0; + } else + $this->_syntax_error("'=' cannot be an attribute value", E_USER_ERROR, __FILE__, __LINE__); + break; + } + $last_token = $token; + } + + if($state != 0) { + if($state == 1) { + $this->_syntax_error("expecting '=' after attribute name '$last_token'", E_USER_ERROR, __FILE__, __LINE__); + } else { + $this->_syntax_error("missing attribute value", E_USER_ERROR, __FILE__, __LINE__); + } + } + + $this->_parse_vars_props($attrs); + + return $attrs; + } + + /** + * compile multiple variables and section properties tokens into + * PHP code + * + * @param array $tokens + */ + function _parse_vars_props(&$tokens) + { + foreach($tokens as $key => $val) { + $tokens[$key] = $this->_parse_var_props($val); + } + } + + /** + * compile single variable and section properties token into + * PHP code + * + * @param string $val + * @param string $tag_attrs + * @return string + */ + function _parse_var_props($val) + { + $val = trim($val); + + if(preg_match('~^(' . $this->_obj_call_regexp . '|' . $this->_dvar_regexp . ')(' . $this->_mod_regexp . '*)$~', $val, $match)) { + // $ variable or object + $return = $this->_parse_var($match[1]); + $modifiers = $match[2]; + if (!empty($this->default_modifiers) && !preg_match('~(^|\|)smarty:nodefaults($|\|)~',$modifiers)) { + $_default_mod_string = implode('|',(array)$this->default_modifiers); + $modifiers = empty($modifiers) ? $_default_mod_string : $_default_mod_string . '|' . $modifiers; + } + $this->_parse_modifiers($return, $modifiers); + return $return; + } elseif (preg_match('~^' . $this->_db_qstr_regexp . '(?:' . $this->_mod_regexp . '*)$~', $val)) { + // double quoted text + preg_match('~^(' . $this->_db_qstr_regexp . ')('. $this->_mod_regexp . '*)$~', $val, $match); + $return = $this->_expand_quoted_text($match[1]); + if($match[2] != '') { + $this->_parse_modifiers($return, $match[2]); + } + return $return; + } + elseif(preg_match('~^' . $this->_num_const_regexp . '(?:' . $this->_mod_regexp . '*)$~', $val)) { + // numerical constant + preg_match('~^(' . $this->_num_const_regexp . ')('. $this->_mod_regexp . '*)$~', $val, $match); + if($match[2] != '') { + $this->_parse_modifiers($match[1], $match[2]); + return $match[1]; + } + } + elseif(preg_match('~^' . $this->_si_qstr_regexp . '(?:' . $this->_mod_regexp . '*)$~', $val)) { + // single quoted text + preg_match('~^(' . $this->_si_qstr_regexp . ')('. $this->_mod_regexp . '*)$~', $val, $match); + if($match[2] != '') { + $this->_parse_modifiers($match[1], $match[2]); + return $match[1]; + } + } + elseif(preg_match('~^' . $this->_cvar_regexp . '(?:' . $this->_mod_regexp . '*)$~', $val)) { + // config var + return $this->_parse_conf_var($val); + } + elseif(preg_match('~^' . $this->_svar_regexp . '(?:' . $this->_mod_regexp . '*)$~', $val)) { + // section var + return $this->_parse_section_prop($val); + } + elseif(!in_array($val, $this->_permitted_tokens) && !is_numeric($val)) { + // literal string + return $this->_expand_quoted_text('"' . strtr($val, array('\\' => '\\\\', '"' => '\\"')) .'"'); + } + return $val; + } + + /** + * expand quoted text with embedded variables + * + * @param string $var_expr + * @return string + */ + function _expand_quoted_text($var_expr) + { + // if contains unescaped $, expand it + if(preg_match_all('~(?:\`(?_dvar_guts_regexp . '(?:' . $this->_obj_ext_regexp . ')*\`)|(?:(?_parse_var(str_replace('`','',$_var)) . ')."'; + } + $var_expr = strtr($var_expr, $_replace); + $_return = preg_replace('~\.""|(?_dvar_math_regexp.'|'.$this->_qstr_regexp.')~', $var_expr, -1, PREG_SPLIT_DELIM_CAPTURE); + + if(count($_math_vars) > 1) { + $_first_var = ""; + $_complete_var = ""; + $_output = ""; + // simple check if there is any math, to stop recursion (due to modifiers with "xx % yy" as parameter) + foreach($_math_vars as $_k => $_math_var) { + $_math_var = $_math_vars[$_k]; + + if(!empty($_math_var) || is_numeric($_math_var)) { + // hit a math operator, so process the stuff which came before it + if(preg_match('~^' . $this->_dvar_math_regexp . '$~', $_math_var)) { + $_has_math = true; + if(!empty($_complete_var) || is_numeric($_complete_var)) { + $_output .= $this->_parse_var($_complete_var); + } + + // just output the math operator to php + $_output .= $_math_var; + + if(empty($_first_var)) + $_first_var = $_complete_var; + + $_complete_var = ""; + } else { + $_complete_var .= $_math_var; + } + } + } + if($_has_math) { + if(!empty($_complete_var) || is_numeric($_complete_var)) + $_output .= $this->_parse_var($_complete_var); + + // get the modifiers working (only the last var from math + modifier is left) + $var_expr = $_complete_var; + } + } + + // prevent cutting of first digit in the number (we _definitly_ got a number if the first char is a digit) + if(is_numeric(substr($var_expr, 0, 1))) + $_var_ref = $var_expr; + else + $_var_ref = substr($var_expr, 1); + + if(!$_has_math) { + + // get [foo] and .foo and ->foo and (...) pieces + preg_match_all('~(?:^\w+)|' . $this->_obj_params_regexp . '|(?:' . $this->_var_bracket_regexp . ')|->\$?\w+|\.\$?\w+|\S+~', $_var_ref, $match); + + $_indexes = $match[0]; + $_var_name = array_shift($_indexes); + + /* Handle $smarty.* variable references as a special case. */ + if ($_var_name == 'smarty') { + /* + * If the reference could be compiled, use the compiled output; + * otherwise, fall back on the $smarty variable generated at + * run-time. + */ + if (($smarty_ref = $this->_compile_smarty_ref($_indexes)) !== null) { + $_output = $smarty_ref; + } else { + $_var_name = substr(array_shift($_indexes), 1); + $_output = "\$this->_smarty_vars['$_var_name']"; + } + } elseif(is_numeric($_var_name) && is_numeric(substr($var_expr, 0, 1))) { + // because . is the operator for accessing arrays thru inidizes we need to put it together again for floating point numbers + if(count($_indexes) > 0) + { + $_var_name .= implode("", $_indexes); + $_indexes = array(); + } + $_output = $_var_name; + } else { + $_output = "\$this->_tpl_vars['$_var_name']"; + } + + foreach ($_indexes as $_index) { + if (substr($_index, 0, 1) == '[') { + $_index = substr($_index, 1, -1); + if (is_numeric($_index)) { + $_output .= "[$_index]"; + } elseif (substr($_index, 0, 1) == '$') { + if (strpos($_index, '.') !== false) { + $_output .= '[' . $this->_parse_var($_index) . ']'; + } else { + $_output .= "[\$this->_tpl_vars['" . substr($_index, 1) . "']]"; + } + } else { + $_var_parts = explode('.', $_index); + $_var_section = $_var_parts[0]; + $_var_section_prop = isset($_var_parts[1]) ? $_var_parts[1] : 'index'; + $_output .= "[\$this->_sections['$_var_section']['$_var_section_prop']]"; + } + } else if (substr($_index, 0, 1) == '.') { + if (substr($_index, 1, 1) == '$') + $_output .= "[\$this->_tpl_vars['" . substr($_index, 2) . "']]"; + else + $_output .= "['" . substr($_index, 1) . "']"; + } else if (substr($_index,0,2) == '->') { + if(substr($_index,2,2) == '__') { + $this->_syntax_error('call to internal object members is not allowed', E_USER_ERROR, __FILE__, __LINE__); + } elseif($this->security && substr($_index, 2, 1) == '_') { + $this->_syntax_error('(secure) call to private object member is not allowed', E_USER_ERROR, __FILE__, __LINE__); + } elseif (substr($_index, 2, 1) == '$') { + if ($this->security) { + $this->_syntax_error('(secure) call to dynamic object member is not allowed', E_USER_ERROR, __FILE__, __LINE__); + } else { + $_output .= '->{(($_var=$this->_tpl_vars[\''.substr($_index,3).'\']) && substr($_var,0,2)!=\'__\') ? $_var : $this->trigger_error("cannot access property \\"$_var\\"")}'; + } + } else { + $_output .= $_index; + } + } elseif (substr($_index, 0, 1) == '(') { + $_index = $this->_parse_parenth_args($_index); + $_output .= $_index; + } else { + $_output .= $_index; + } + } + } + + return $_output; + } + + /** + * parse arguments in function call parenthesis + * + * @param string $parenth_args + * @return string + */ + function _parse_parenth_args($parenth_args) + { + preg_match_all('~' . $this->_param_regexp . '~',$parenth_args, $match); + $orig_vals = $match = $match[0]; + $this->_parse_vars_props($match); + $replace = array(); + for ($i = 0, $count = count($match); $i < $count; $i++) { + $replace[$orig_vals[$i]] = $match[$i]; + } + return strtr($parenth_args, $replace); + } + + /** + * parse configuration variable expression into PHP code + * + * @param string $conf_var_expr + */ + function _parse_conf_var($conf_var_expr) + { + $parts = explode('|', $conf_var_expr, 2); + $var_ref = $parts[0]; + $modifiers = isset($parts[1]) ? $parts[1] : ''; + + $var_name = substr($var_ref, 1, -1); + + $output = "\$this->_config[0]['vars']['$var_name']"; + + $this->_parse_modifiers($output, $modifiers); + + return $output; + } + + /** + * parse section property expression into PHP code + * + * @param string $section_prop_expr + * @return string + */ + function _parse_section_prop($section_prop_expr) + { + $parts = explode('|', $section_prop_expr, 2); + $var_ref = $parts[0]; + $modifiers = isset($parts[1]) ? $parts[1] : ''; + + preg_match('!%(\w+)\.(\w+)%!', $var_ref, $match); + $section_name = $match[1]; + $prop_name = $match[2]; + + $output = "\$this->_sections['$section_name']['$prop_name']"; + + $this->_parse_modifiers($output, $modifiers); + + return $output; + } + + + /** + * parse modifier chain into PHP code + * + * sets $output to parsed modified chain + * @param string $output + * @param string $modifier_string + */ + function _parse_modifiers(&$output, $modifier_string) + { + preg_match_all('~\|(@?\w+)((?>:(?:'. $this->_qstr_regexp . '|[^|]+))*)~', '|' . $modifier_string, $_match); + list(, $_modifiers, $modifier_arg_strings) = $_match; + + for ($_i = 0, $_for_max = count($_modifiers); $_i < $_for_max; $_i++) { + $_modifier_name = $_modifiers[$_i]; + + if($_modifier_name == 'smarty') { + // skip smarty modifier + continue; + } + + preg_match_all('~:(' . $this->_qstr_regexp . '|[^:]+)~', $modifier_arg_strings[$_i], $_match); + $_modifier_args = $_match[1]; + + if (substr($_modifier_name, 0, 1) == '@') { + $_map_array = false; + $_modifier_name = substr($_modifier_name, 1); + } else { + $_map_array = true; + } + + if (empty($this->_plugins['modifier'][$_modifier_name]) + && !$this->_get_plugin_filepath('modifier', $_modifier_name) + && function_exists($_modifier_name)) { + if ($this->security && !in_array($_modifier_name, $this->security_settings['MODIFIER_FUNCS'])) { + $this->_trigger_fatal_error("[plugin] (secure mode) modifier '$_modifier_name' is not allowed" , $this->_current_file, $this->_current_line_no, __FILE__, __LINE__); + } else { + $this->_plugins['modifier'][$_modifier_name] = array($_modifier_name, null, null, false); + } + } + $this->_add_plugin('modifier', $_modifier_name); + + $this->_parse_vars_props($_modifier_args); + + if($_modifier_name == 'default') { + // supress notifications of default modifier vars and args + if(substr($output, 0, 1) == '$') { + $output = '@' . $output; + } + if(isset($_modifier_args[0]) && substr($_modifier_args[0], 0, 1) == '$') { + $_modifier_args[0] = '@' . $_modifier_args[0]; + } + } + if (count($_modifier_args) > 0) + $_modifier_args = ', '.implode(', ', $_modifier_args); + else + $_modifier_args = ''; + + if ($_map_array) { + $output = "((is_array(\$_tmp=$output)) ? \$this->_run_mod_handler('$_modifier_name', true, \$_tmp$_modifier_args) : " . $this->_compile_plugin_call('modifier', $_modifier_name) . "(\$_tmp$_modifier_args))"; + + } else { + + $output = $this->_compile_plugin_call('modifier', $_modifier_name)."($output$_modifier_args)"; + + } + } + } + + + /** + * add plugin + * + * @param string $type + * @param string $name + * @param boolean? $delayed_loading + */ + function _add_plugin($type, $name, $delayed_loading = null) + { + if (!isset($this->_plugin_info[$type])) { + $this->_plugin_info[$type] = array(); + } + if (!isset($this->_plugin_info[$type][$name])) { + $this->_plugin_info[$type][$name] = array($this->_current_file, + $this->_current_line_no, + $delayed_loading); + } + } + + + /** + * Compiles references of type $smarty.foo + * + * @param string $indexes + * @return string + */ + function _compile_smarty_ref(&$indexes) + { + /* Extract the reference name. */ + $_ref = substr($indexes[0], 1); + foreach($indexes as $_index_no=>$_index) { + if (substr($_index, 0, 1) != '.' && $_index_no<2 || !preg_match('~^(\.|\[|->)~', $_index)) { + $this->_syntax_error('$smarty' . implode('', array_slice($indexes, 0, 2)) . ' is an invalid reference', E_USER_ERROR, __FILE__, __LINE__); + } + } + + switch ($_ref) { + case 'now': + $compiled_ref = 'time()'; + $_max_index = 1; + break; + + case 'foreach': + array_shift($indexes); + $_var = $this->_parse_var_props(substr($indexes[0], 1)); + $_propname = substr($indexes[1], 1); + $_max_index = 1; + switch ($_propname) { + case 'index': + array_shift($indexes); + $compiled_ref = "(\$this->_foreach[$_var]['iteration']-1)"; + break; + + case 'first': + array_shift($indexes); + $compiled_ref = "(\$this->_foreach[$_var]['iteration'] <= 1)"; + break; + + case 'last': + array_shift($indexes); + $compiled_ref = "(\$this->_foreach[$_var]['iteration'] == \$this->_foreach[$_var]['total'])"; + break; + + case 'show': + array_shift($indexes); + $compiled_ref = "(\$this->_foreach[$_var]['total'] > 0)"; + break; + + default: + unset($_max_index); + $compiled_ref = "\$this->_foreach[$_var]"; + } + break; + + case 'section': + array_shift($indexes); + $_var = $this->_parse_var_props(substr($indexes[0], 1)); + $compiled_ref = "\$this->_sections[$_var]"; + break; + + case 'get': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_GET"; + break; + + case 'post': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_POST"; + break; + + case 'cookies': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_COOKIE"; + break; + + case 'env': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_ENV"; + break; + + case 'server': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_SERVER"; + break; + + case 'session': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + $compiled_ref = "\$_SESSION"; + break; + + /* + * These cases are handled either at run-time or elsewhere in the + * compiler. + */ + case 'request': + if ($this->security && !$this->security_settings['ALLOW_SUPER_GLOBALS']) { + $this->_syntax_error("(secure mode) super global access not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + if ($this->request_use_auto_globals) { + $compiled_ref = "\$_REQUEST"; + break; + } else { + $this->_init_smarty_vars = true; + } + return null; + + case 'capture': + return null; + + case 'template': + $compiled_ref = "'$this->_current_file'"; + $_max_index = 1; + break; + + case 'version': + $compiled_ref = "'$this->_version'"; + $_max_index = 1; + break; + + case 'const': + if ($this->security && !$this->security_settings['ALLOW_CONSTANTS']) { + $this->_syntax_error("(secure mode) constants not permitted", + E_USER_WARNING, __FILE__, __LINE__); + return; + } + array_shift($indexes); + if (preg_match('!^\.\w+$!', $indexes[0])) { + $compiled_ref = '@' . substr($indexes[0], 1); + } else { + $_val = $this->_parse_var_props(substr($indexes[0], 1)); + $compiled_ref = '@constant(' . $_val . ')'; + } + $_max_index = 1; + break; + + case 'config': + $compiled_ref = "\$this->_config[0]['vars']"; + $_max_index = 3; + break; + + case 'ldelim': + $compiled_ref = "'$this->left_delimiter'"; + break; + + case 'rdelim': + $compiled_ref = "'$this->right_delimiter'"; + break; + + default: + $this->_syntax_error('$smarty.' . $_ref . ' is an unknown reference', E_USER_ERROR, __FILE__, __LINE__); + break; + } + + if (isset($_max_index) && count($indexes) > $_max_index) { + $this->_syntax_error('$smarty' . implode('', $indexes) .' is an invalid reference', E_USER_ERROR, __FILE__, __LINE__); + } + + array_shift($indexes); + return $compiled_ref; + } + + /** + * compiles call to plugin of type $type with name $name + * returns a string containing the function-name or method call + * without the paramter-list that would have follow to make the + * call valid php-syntax + * + * @param string $type + * @param string $name + * @return string + */ + function _compile_plugin_call($type, $name) { + if (isset($this->_plugins[$type][$name])) { + /* plugin loaded */ + if (is_array($this->_plugins[$type][$name][0])) { + return ((is_object($this->_plugins[$type][$name][0][0])) ? + "\$this->_plugins['$type']['$name'][0][0]->" /* method callback */ + : (string)($this->_plugins[$type][$name][0][0]).'::' /* class callback */ + ). $this->_plugins[$type][$name][0][1]; + + } else { + /* function callback */ + return $this->_plugins[$type][$name][0]; + + } + } else { + /* plugin not loaded -> auto-loadable-plugin */ + return 'smarty_'.$type.'_'.$name; + + } + } + + /** + * load pre- and post-filters + */ + function _load_filters() + { + if (count($this->_plugins['prefilter']) > 0) { + foreach ($this->_plugins['prefilter'] as $filter_name => $prefilter) { + if ($prefilter === false) { + unset($this->_plugins['prefilter'][$filter_name]); + $_params = array('plugins' => array(array('prefilter', $filter_name, null, null, false))); + require_once(SMARTY_CORE_DIR . 'core.load_plugins.php'); + smarty_core_load_plugins($_params, $this); + } + } + } + if (count($this->_plugins['postfilter']) > 0) { + foreach ($this->_plugins['postfilter'] as $filter_name => $postfilter) { + if ($postfilter === false) { + unset($this->_plugins['postfilter'][$filter_name]); + $_params = array('plugins' => array(array('postfilter', $filter_name, null, null, false))); + require_once(SMARTY_CORE_DIR . 'core.load_plugins.php'); + smarty_core_load_plugins($_params, $this); + } + } + } + } + + + /** + * Quote subpattern references + * + * @param string $string + * @return string + */ + function _quote_replace($string) + { + return strtr($string, array('\\' => '\\\\', '$' => '\\$')); + } + + /** + * display Smarty syntax error + * + * @param string $error_msg + * @param integer $error_type + * @param string $file + * @param integer $line + */ + function _syntax_error($error_msg, $error_type = E_USER_ERROR, $file=null, $line=null) + { + $this->_trigger_fatal_error("syntax error: $error_msg", $this->_current_file, $this->_current_line_no, $file, $line, $error_type); + } + + + /** + * check if the compilation changes from cacheable to + * non-cacheable state with the beginning of the current + * plugin. return php-code to reflect the transition. + * @return string + */ + function _push_cacheable_state($type, $name) { + $_cacheable = !isset($this->_plugins[$type][$name]) || $this->_plugins[$type][$name][4]; + if ($_cacheable + || 0<$this->_cacheable_state++) return ''; + if (!isset($this->_cache_serial)) $this->_cache_serial = md5(uniqid('Smarty')); + $_ret = 'if ($this->caching && !$this->_cache_including): echo \'{nocache:' + . $this->_cache_serial . '#' . $this->_nocache_count + . '}\'; endif;'; + return $_ret; + } + + + /** + * check if the compilation changes from non-cacheable to + * cacheable state with the end of the current plugin return + * php-code to reflect the transition. + * @return string + */ + function _pop_cacheable_state($type, $name) { + $_cacheable = !isset($this->_plugins[$type][$name]) || $this->_plugins[$type][$name][4]; + if ($_cacheable + || --$this->_cacheable_state>0) return ''; + return 'if ($this->caching && !$this->_cache_including): echo \'{/nocache:' + . $this->_cache_serial . '#' . ($this->_nocache_count++) + . '}\'; endif;'; + } + + + /** + * push opening tag-name, file-name and line-number on the tag-stack + * @param string the opening tag's name + */ + function _push_tag($open_tag) + { + array_push($this->_tag_stack, array($open_tag, $this->_current_line_no)); + } + + /** + * pop closing tag-name + * raise an error if this stack-top doesn't match with the closing tag + * @param string the closing tag's name + * @return string the opening tag's name + */ + function _pop_tag($close_tag) + { + $message = ''; + if (count($this->_tag_stack)>0) { + list($_open_tag, $_line_no) = array_pop($this->_tag_stack); + if ($close_tag == $_open_tag) { + return $_open_tag; + } + if ($close_tag == 'if' && ($_open_tag == 'else' || $_open_tag == 'elseif' )) { + return $this->_pop_tag($close_tag); + } + if ($close_tag == 'section' && $_open_tag == 'sectionelse') { + $this->_pop_tag($close_tag); + return $_open_tag; + } + if ($close_tag == 'foreach' && $_open_tag == 'foreachelse') { + $this->_pop_tag($close_tag); + return $_open_tag; + } + if ($_open_tag == 'else' || $_open_tag == 'elseif') { + $_open_tag = 'if'; + } elseif ($_open_tag == 'sectionelse') { + $_open_tag = 'section'; + } elseif ($_open_tag == 'foreachelse') { + $_open_tag = 'foreach'; + } + $message = " expected {/$_open_tag} (opened line $_line_no)."; + } + $this->_syntax_error("mismatched tag {/$close_tag}.$message", + E_USER_ERROR, __FILE__, __LINE__); + } + +} + +/** + * compare to values by their string length + * + * @access private + * @param string $a + * @param string $b + * @return 0|-1|1 + */ +function _smarty_sort_length($a, $b) +{ + if($a == $b) + return 0; + + if(strlen($a) == strlen($b)) + return ($a > $b) ? -1 : 1; + + return (strlen($a) > strlen($b)) ? -1 : 1; +} + + +/* vim: set et: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/debug.tpl b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/debug.tpl new file mode 100644 index 0000000..c05ef5d --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/debug.tpl @@ -0,0 +1,157 @@ +{* Smarty *} +{* debug.tpl, last updated version 2.1.0 *} +{assign_debug_info} +{capture assign=debug_output} + + + + Smarty Debug Console +{literal} + +{/literal} + + + +

Smarty Debug Console

+ +

included templates & config files (load time in seconds)

+ +
+{section name=templates loop=$_debug_tpls} + {section name=indent loop=$_debug_tpls[templates].depth}   {/section} + + {$_debug_tpls[templates].filename|escape:html} + {if isset($_debug_tpls[templates].exec_time)} + + ({$_debug_tpls[templates].exec_time|string_format:"%.5f"}) + {if %templates.index% eq 0}(total){/if} + + {/if} +
+{sectionelse} +

no templates included

+{/section} +
+ +

assigned template variables

+ + + {section name=vars loop=$_debug_keys} + + + + {sectionelse} + + {/section} +
{ldelim}${$_debug_keys[vars]|escape:'html'}{rdelim}{$_debug_vals[vars]|@debug_print_var}

no template variables assigned

+ +

assigned config file variables (outer template scope)

+ + + {section name=config_vars loop=$_debug_config_keys} + + + + {sectionelse} + + {/section} +
{ldelim}#{$_debug_config_keys[config_vars]|escape:'html'}#{rdelim}{$_debug_config_vals[config_vars]|@debug_print_var}

no config vars assigned

+ + +{/capture} +{if isset($_smarty_debug_output) and $_smarty_debug_output eq "html"} + {$debug_output} +{else} + +{/if} \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assemble_plugin_filepath.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assemble_plugin_filepath.php new file mode 100644 index 0000000..690d3dd --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assemble_plugin_filepath.php @@ -0,0 +1,67 @@ +plugins_dir as $_plugin_dir) { + + $_plugin_filepath = $_plugin_dir . DIRECTORY_SEPARATOR . $_plugin_filename; + + // see if path is relative + if (!preg_match("/^([\/\\\\]|[a-zA-Z]:[\/\\\\])/", $_plugin_dir)) { + $_relative_paths[] = $_plugin_dir; + // relative path, see if it is in the SMARTY_DIR + if (@is_readable(SMARTY_DIR . $_plugin_filepath)) { + $_return = SMARTY_DIR . $_plugin_filepath; + break; + } + } + // try relative to cwd (or absolute) + if (@is_readable($_plugin_filepath)) { + $_return = $_plugin_filepath; + break; + } + } + + if($_return === false) { + // still not found, try PHP include_path + if(isset($_relative_paths)) { + foreach ((array)$_relative_paths as $_plugin_dir) { + + $_plugin_filepath = $_plugin_dir . DIRECTORY_SEPARATOR . $_plugin_filename; + + $_params = array('file_path' => $_plugin_filepath); + require_once(SMARTY_CORE_DIR . 'core.get_include_path.php'); + if(smarty_core_get_include_path($_params, $smarty)) { + $_return = $_params['new_file_path']; + break; + } + } + } + } + $_filepaths_cache[$_plugin_filename] = $_return; + return $_return; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assign_smarty_interface.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assign_smarty_interface.php new file mode 100644 index 0000000..7e65a73 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.assign_smarty_interface.php @@ -0,0 +1,43 @@ + + * Name: assign_smarty_interface
+ * Purpose: assign the $smarty interface variable + * @param array Format: null + * @param Smarty + */ +function smarty_core_assign_smarty_interface($params, &$smarty) +{ + if (isset($smarty->_smarty_vars) && isset($smarty->_smarty_vars['request'])) { + return; + } + + $_globals_map = array('g' => 'HTTP_GET_VARS', + 'p' => 'HTTP_POST_VARS', + 'c' => 'HTTP_COOKIE_VARS', + 's' => 'HTTP_SERVER_VARS', + 'e' => 'HTTP_ENV_VARS'); + + $_smarty_vars_request = array(); + + foreach (preg_split('!!', strtolower($smarty->request_vars_order)) as $_c) { + if (isset($_globals_map[$_c])) { + $_smarty_vars_request = array_merge($_smarty_vars_request, $GLOBALS[$_globals_map[$_c]]); + } + } + $_smarty_vars_request = @array_merge($_smarty_vars_request, $GLOBALS['HTTP_SESSION_VARS']); + + $smarty->_smarty_vars['request'] = $_smarty_vars_request; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.create_dir_structure.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.create_dir_structure.php new file mode 100644 index 0000000..3eecc49 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.create_dir_structure.php @@ -0,0 +1,79 @@ +_dir_perms) && !is_dir($_new_dir)) { + $smarty->trigger_error("problem creating directory '" . $_new_dir . "'"); + return false; + } + $_new_dir .= '/'; + } + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.display_debug_console.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.display_debug_console.php new file mode 100644 index 0000000..1a80f39 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.display_debug_console.php @@ -0,0 +1,61 @@ + + * Name: display_debug_console
+ * Purpose: display the javascript debug console window + * @param array Format: null + * @param Smarty + */ +function smarty_core_display_debug_console($params, &$smarty) +{ + // we must force compile the debug template in case the environment + // changed between separate applications. + + if(empty($smarty->debug_tpl)) { + // set path to debug template from SMARTY_DIR + $smarty->debug_tpl = SMARTY_DIR . 'debug.tpl'; + if($smarty->security && is_file($smarty->debug_tpl)) { + $smarty->secure_dir[] = realpath($smarty->debug_tpl); + } + $smarty->debug_tpl = 'file:' . SMARTY_DIR . 'debug.tpl'; + } + + $_ldelim_orig = $smarty->left_delimiter; + $_rdelim_orig = $smarty->right_delimiter; + + $smarty->left_delimiter = '{'; + $smarty->right_delimiter = '}'; + + $_compile_id_orig = $smarty->_compile_id; + $smarty->_compile_id = null; + + $_compile_path = $smarty->_get_compile_path($smarty->debug_tpl); + if ($smarty->_compile_resource($smarty->debug_tpl, $_compile_path)) + { + ob_start(); + $smarty->_include($_compile_path); + $_results = ob_get_contents(); + ob_end_clean(); + } else { + $_results = ''; + } + + $smarty->_compile_id = $_compile_id_orig; + + $smarty->left_delimiter = $_ldelim_orig; + $smarty->right_delimiter = $_rdelim_orig; + + return $_results; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_include_path.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_include_path.php new file mode 100644 index 0000000..4343241 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_include_path.php @@ -0,0 +1,44 @@ + diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_microtime.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_microtime.php new file mode 100644 index 0000000..f1a28e0 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_microtime.php @@ -0,0 +1,23 @@ + diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_php_resource.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_php_resource.php new file mode 100644 index 0000000..786d4e7 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.get_php_resource.php @@ -0,0 +1,80 @@ +trusted_dir; + $smarty->_parse_resource_name($params, $smarty); + + /* + * Find out if the resource exists. + */ + + if ($params['resource_type'] == 'file') { + $_readable = false; + if(file_exists($params['resource_name']) && is_readable($params['resource_name'])) { + $_readable = true; + } else { + // test for file in include_path + $_params = array('file_path' => $params['resource_name']); + require_once(SMARTY_CORE_DIR . 'core.get_include_path.php'); + if(smarty_core_get_include_path($_params, $smarty)) { + $_include_path = $_params['new_file_path']; + $_readable = true; + } + } + } else if ($params['resource_type'] != 'file') { + $_template_source = null; + $_readable = is_callable($smarty->_plugins['resource'][$params['resource_type']][0][0]) + && call_user_func_array($smarty->_plugins['resource'][$params['resource_type']][0][0], + array($params['resource_name'], &$_template_source, &$smarty)); + } + + /* + * Set the error function, depending on which class calls us. + */ + if (method_exists($smarty, '_syntax_error')) { + $_error_funcc = '_syntax_error'; + } else { + $_error_funcc = 'trigger_error'; + } + + if ($_readable) { + if ($smarty->security) { + require_once(SMARTY_CORE_DIR . 'core.is_trusted.php'); + if (!smarty_core_is_trusted($params, $smarty)) { + $smarty->$_error_funcc('(secure mode) ' . $params['resource_type'] . ':' . $params['resource_name'] . ' is not trusted'); + return false; + } + } + } else { + $smarty->$_error_funcc($params['resource_type'] . ':' . $params['resource_name'] . ' is not readable'); + return false; + } + + if ($params['resource_type'] == 'file') { + $params['php_resource'] = $params['resource_name']; + } else { + $params['php_resource'] = $_template_source; + } + return true; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_secure.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_secure.php new file mode 100644 index 0000000..d54abd4 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_secure.php @@ -0,0 +1,59 @@ +security || $smarty->security_settings['INCLUDE_ANY']) { + return true; + } + + if ($params['resource_type'] == 'file') { + $_rp = realpath($params['resource_name']); + if (isset($params['resource_base_path'])) { + foreach ((array)$params['resource_base_path'] as $curr_dir) { + if ( ($_cd = realpath($curr_dir)) !== false && + strncmp($_rp, $_cd, strlen($_cd)) == 0 && + substr($_rp, strlen($_cd), 1) == DIRECTORY_SEPARATOR ) { + return true; + } + } + } + if (!empty($smarty->secure_dir)) { + foreach ((array)$smarty->secure_dir as $curr_dir) { + if ( ($_cd = realpath($curr_dir)) !== false) { + if($_cd == $_rp) { + return true; + } elseif (strncmp($_rp, $_cd, strlen($_cd)) == 0 && + substr($_rp, strlen($_cd), 1) == DIRECTORY_SEPARATOR) { + return true; + } + } + } + } + } else { + // resource is not on local file system + return call_user_func_array( + $smarty->_plugins['resource'][$params['resource_type']][0][2], + array($params['resource_name'], &$smarty)); + } + + return false; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_trusted.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_trusted.php new file mode 100644 index 0000000..4299731 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.is_trusted.php @@ -0,0 +1,47 @@ +trusted_dir)) { + $_rp = realpath($params['resource_name']); + foreach ((array)$smarty->trusted_dir as $curr_dir) { + if (!empty($curr_dir) && is_readable ($curr_dir)) { + $_cd = realpath($curr_dir); + if (strncmp($_rp, $_cd, strlen($_cd)) == 0 + && substr($_rp, strlen($_cd), 1) == DIRECTORY_SEPARATOR ) { + $_smarty_trusted = true; + break; + } + } + } + } + + } else { + // resource is not on local file system + $_smarty_trusted = call_user_func_array($smarty->_plugins['resource'][$params['resource_type']][0][3], + array($params['resource_name'], $smarty)); + } + + return $_smarty_trusted; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_plugins.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_plugins.php new file mode 100644 index 0000000..6db1dc5 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_plugins.php @@ -0,0 +1,125 @@ +_plugins[$_type][$_name]; + + /* + * We do not load plugin more than once for each instance of Smarty. + * The following code checks for that. The plugin can also be + * registered dynamically at runtime, in which case template file + * and line number will be unknown, so we fill them in. + * + * The final element of the info array is a flag that indicates + * whether the dynamically registered plugin function has been + * checked for existence yet or not. + */ + if (isset($_plugin)) { + if (empty($_plugin[3])) { + if (!is_callable($_plugin[0])) { + $smarty->_trigger_fatal_error("[plugin] $_type '$_name' is not implemented", $_tpl_file, $_tpl_line, __FILE__, __LINE__); + } else { + $_plugin[1] = $_tpl_file; + $_plugin[2] = $_tpl_line; + $_plugin[3] = true; + if (!isset($_plugin[4])) $_plugin[4] = true; /* cacheable */ + } + } + continue; + } else if ($_type == 'insert') { + /* + * For backwards compatibility, we check for insert functions in + * the symbol table before trying to load them as a plugin. + */ + $_plugin_func = 'insert_' . $_name; + if (function_exists($_plugin_func)) { + $_plugin = array($_plugin_func, $_tpl_file, $_tpl_line, true, false); + continue; + } + } + + $_plugin_file = $smarty->_get_plugin_filepath($_type, $_name); + + if (! $_found = ($_plugin_file != false)) { + $_message = "could not load plugin file '$_type.$_name.php'\n"; + } + + /* + * If plugin file is found, it -must- provide the properly named + * plugin function. In case it doesn't, simply output the error and + * do not fall back on any other method. + */ + if ($_found) { + include_once $_plugin_file; + + $_plugin_func = 'smarty_' . $_type . '_' . $_name; + if (!function_exists($_plugin_func)) { + $smarty->_trigger_fatal_error("[plugin] function $_plugin_func() not found in $_plugin_file", $_tpl_file, $_tpl_line, __FILE__, __LINE__); + continue; + } + } + /* + * In case of insert plugins, their code may be loaded later via + * 'script' attribute. + */ + else if ($_type == 'insert' && $_delayed_loading) { + $_plugin_func = 'smarty_' . $_type . '_' . $_name; + $_found = true; + } + + /* + * Plugin specific processing and error checking. + */ + if (!$_found) { + if ($_type == 'modifier') { + /* + * In case modifier falls back on using PHP functions + * directly, we only allow those specified in the security + * context. + */ + if ($smarty->security && !in_array($_name, $smarty->security_settings['MODIFIER_FUNCS'])) { + $_message = "(secure mode) modifier '$_name' is not allowed"; + } else { + if (!function_exists($_name)) { + $_message = "modifier '$_name' is not implemented"; + } else { + $_plugin_func = $_name; + $_found = true; + } + } + } else if ($_type == 'function') { + /* + * This is a catch-all situation. + */ + $_message = "unknown tag - '$_name'"; + } + } + + if ($_found) { + $smarty->_plugins[$_type][$_name] = array($_plugin_func, $_tpl_file, $_tpl_line, true, true); + } else { + // output error + $smarty->_trigger_fatal_error('[plugin] ' . $_message, $_tpl_file, $_tpl_line, __FILE__, __LINE__); + } + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_resource_plugin.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_resource_plugin.php new file mode 100644 index 0000000..a7d37d1 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.load_resource_plugin.php @@ -0,0 +1,74 @@ +_plugins['resource'][$params['type']]; + if (isset($_plugin)) { + if (!$_plugin[1] && count($_plugin[0])) { + $_plugin[1] = true; + foreach ($_plugin[0] as $_plugin_func) { + if (!is_callable($_plugin_func)) { + $_plugin[1] = false; + break; + } + } + } + + if (!$_plugin[1]) { + $smarty->_trigger_fatal_error("[plugin] resource '" . $params['type'] . "' is not implemented", null, null, __FILE__, __LINE__); + } + + return; + } + + $_plugin_file = $smarty->_get_plugin_filepath('resource', $params['type']); + $_found = ($_plugin_file != false); + + if ($_found) { /* + * If the plugin file is found, it -must- provide the properly named + * plugin functions. + */ + include_once($_plugin_file); + + /* + * Locate functions that we require the plugin to provide. + */ + $_resource_ops = array('source', 'timestamp', 'secure', 'trusted'); + $_resource_funcs = array(); + foreach ($_resource_ops as $_op) { + $_plugin_func = 'smarty_resource_' . $params['type'] . '_' . $_op; + if (!function_exists($_plugin_func)) { + $smarty->_trigger_fatal_error("[plugin] function $_plugin_func() not found in $_plugin_file", null, null, __FILE__, __LINE__); + return; + } else { + $_resource_funcs[] = $_plugin_func; + } + } + + $smarty->_plugins['resource'][$params['type']] = array($_resource_funcs, true); + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_cached_inserts.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_cached_inserts.php new file mode 100644 index 0000000..1d78edd --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_cached_inserts.php @@ -0,0 +1,71 @@ +_smarty_md5.'{insert_cache (.*)}'.$smarty->_smarty_md5.'!Uis', + $params['results'], $match); + list($cached_inserts, $insert_args) = $match; + + for ($i = 0, $for_max = count($cached_inserts); $i < $for_max; $i++) { + if ($smarty->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $debug_start_time = smarty_core_get_microtime($_params, $smarty); + } + + $args = unserialize($insert_args[$i]); + $name = $args['name']; + + if (isset($args['script'])) { + $_params = array('resource_name' => $smarty->_dequote($args['script'])); + require_once(SMARTY_CORE_DIR . 'core.get_php_resource.php'); + if(!smarty_core_get_php_resource($_params, $smarty)) { + return false; + } + $resource_type = $_params['resource_type']; + $php_resource = $_params['php_resource']; + + + if ($resource_type == 'file') { + $smarty->_include($php_resource, true); + } else { + $smarty->_eval($php_resource); + } + } + + $function_name = $smarty->_plugins['insert'][$name][0]; + if (empty($args['assign'])) { + $replace = $function_name($args, $smarty); + } else { + $smarty->assign($args['assign'], $function_name($args, $smarty)); + $replace = ''; + } + + $params['results'] = substr_replace($params['results'], $replace, strpos($params['results'], $cached_inserts[$i]), strlen($cached_inserts[$i])); + if ($smarty->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $smarty->_smarty_debug_info[] = array('type' => 'insert', + 'filename' => 'insert_'.$name, + 'depth' => $smarty->_inclusion_depth, + 'exec_time' => smarty_core_get_microtime($_params, $smarty) - $debug_start_time); + } + } + + return $params['results']; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_compiled_include.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_compiled_include.php new file mode 100644 index 0000000..904d597 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.process_compiled_include.php @@ -0,0 +1,37 @@ +_cache_including; + $smarty->_cache_including = true; + + $_return = $params['results']; + + foreach ($smarty->_cache_info['cache_serials'] as $_include_file_path=>$_cache_serial) { + $smarty->_include($_include_file_path, true); + } + + foreach ($smarty->_cache_info['cache_serials'] as $_include_file_path=>$_cache_serial) { + $_return = preg_replace_callback('!(\{nocache\:('.$_cache_serial.')#(\d+)\})!s', + array(&$smarty, '_process_compiled_include_callback'), + $_return); + } + $smarty->_cache_including = $_cache_including; + return $_return; +} + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.read_cache_file.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.read_cache_file.php new file mode 100644 index 0000000..c60e113 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.read_cache_file.php @@ -0,0 +1,101 @@ +force_compile) { + // force compile enabled, always regenerate + return false; + } + + if (isset($content_cache[$params['tpl_file'].','.$params['cache_id'].','.$params['compile_id']])) { + list($params['results'], $smarty->_cache_info) = $content_cache[$params['tpl_file'].','.$params['cache_id'].','.$params['compile_id']]; + return true; + } + + if (!empty($smarty->cache_handler_func)) { + // use cache_handler function + call_user_func_array($smarty->cache_handler_func, + array('read', &$smarty, &$params['results'], $params['tpl_file'], $params['cache_id'], $params['compile_id'], null)); + } else { + // use local cache file + $_auto_id = $smarty->_get_auto_id($params['cache_id'], $params['compile_id']); + $_cache_file = $smarty->_get_auto_filename($smarty->cache_dir, $params['tpl_file'], $_auto_id); + $params['results'] = $smarty->_read_file($_cache_file); + } + + if (empty($params['results'])) { + // nothing to parse (error?), regenerate cache + return false; + } + + $_contents = $params['results']; + $_info_start = strpos($_contents, "\n") + 1; + $_info_len = (int)substr($_contents, 0, $_info_start - 1); + $_cache_info = unserialize(substr($_contents, $_info_start, $_info_len)); + $params['results'] = substr($_contents, $_info_start + $_info_len); + + if ($smarty->caching == 2 && isset ($_cache_info['expires'])){ + // caching by expiration time + if ($_cache_info['expires'] > -1 && (time() > $_cache_info['expires'])) { + // cache expired, regenerate + return false; + } + } else { + // caching by lifetime + if ($smarty->cache_lifetime > -1 && (time() - $_cache_info['timestamp'] > $smarty->cache_lifetime)) { + // cache expired, regenerate + return false; + } + } + + if ($smarty->compile_check) { + $_params = array('get_source' => false, 'quiet'=>true); + foreach (array_keys($_cache_info['template']) as $_template_dep) { + $_params['resource_name'] = $_template_dep; + if (!$smarty->_fetch_resource_info($_params) || $_cache_info['timestamp'] < $_params['resource_timestamp']) { + // template file has changed, regenerate cache + return false; + } + } + + if (isset($_cache_info['config'])) { + $_params = array('resource_base_path' => $smarty->config_dir, 'get_source' => false, 'quiet'=>true); + foreach (array_keys($_cache_info['config']) as $_config_dep) { + $_params['resource_name'] = $_config_dep; + if (!$smarty->_fetch_resource_info($_params) || $_cache_info['timestamp'] < $_params['resource_timestamp']) { + // config file has changed, regenerate cache + return false; + } + } + } + } + + $content_cache[$params['tpl_file'].','.$params['cache_id'].','.$params['compile_id']] = array($params['results'], $_cache_info); + + $smarty->_cache_info = $_cache_info; + return true; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rm_auto.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rm_auto.php new file mode 100644 index 0000000..b251f64 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rm_auto.php @@ -0,0 +1,71 @@ + $params['auto_base'], + 'level' => 0, + 'exp_time' => $params['exp_time'] + ); + require_once(SMARTY_CORE_DIR . 'core.rmdir.php'); + $_res = smarty_core_rmdir($_params, $smarty); + } else { + $_tname = $smarty->_get_auto_filename($params['auto_base'], $params['auto_source'], $params['auto_id']); + + if(isset($params['auto_source'])) { + if (isset($params['extensions'])) { + $_res = false; + foreach ((array)$params['extensions'] as $_extension) + $_res |= $smarty->_unlink($_tname.$_extension, $params['exp_time']); + } else { + $_res = $smarty->_unlink($_tname, $params['exp_time']); + } + } elseif ($smarty->use_sub_dirs) { + $_params = array( + 'dirname' => $_tname, + 'level' => 1, + 'exp_time' => $params['exp_time'] + ); + require_once(SMARTY_CORE_DIR . 'core.rmdir.php'); + $_res = smarty_core_rmdir($_params, $smarty); + } else { + // remove matching file names + $_handle = opendir($params['auto_base']); + $_res = true; + while (false !== ($_filename = readdir($_handle))) { + if($_filename == '.' || $_filename == '..') { + continue; + } elseif (substr($params['auto_base'] . DIRECTORY_SEPARATOR . $_filename, 0, strlen($_tname)) == $_tname) { + $_res &= (bool)$smarty->_unlink($params['auto_base'] . DIRECTORY_SEPARATOR . $_filename, $params['exp_time']); + } + } + } + } + + return $_res; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rmdir.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rmdir.php new file mode 100644 index 0000000..2166c44 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.rmdir.php @@ -0,0 +1,54 @@ + keep root) + * WARNING: no tests, it will try to remove what you tell it! + * + * @param string $dirname + * @param integer $level + * @param integer $exp_time + * @return boolean + */ + +// $dirname, $level = 1, $exp_time = null + +function smarty_core_rmdir($params, &$smarty) +{ + if(!isset($params['level'])) { $params['level'] = 1; } + if(!isset($params['exp_time'])) { $params['exp_time'] = null; } + + if($_handle = @opendir($params['dirname'])) { + + while (false !== ($_entry = readdir($_handle))) { + if ($_entry != '.' && $_entry != '..') { + if (@is_dir($params['dirname'] . DIRECTORY_SEPARATOR . $_entry)) { + $_params = array( + 'dirname' => $params['dirname'] . DIRECTORY_SEPARATOR . $_entry, + 'level' => $params['level'] + 1, + 'exp_time' => $params['exp_time'] + ); + smarty_core_rmdir($_params, $smarty); + } + else { + $smarty->_unlink($params['dirname'] . DIRECTORY_SEPARATOR . $_entry, $params['exp_time']); + } + } + } + closedir($_handle); + } + + if ($params['level']) { + return @rmdir($params['dirname']); + } + return (bool)$_handle; + +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.run_insert_handler.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.run_insert_handler.php new file mode 100644 index 0000000..71c3845 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.run_insert_handler.php @@ -0,0 +1,71 @@ +debugging) { + $_params = array(); + $_debug_start_time = smarty_core_get_microtime($_params, $smarty); + } + + if ($smarty->caching) { + $_arg_string = serialize($params['args']); + $_name = $params['args']['name']; + if (!isset($smarty->_cache_info['insert_tags'][$_name])) { + $smarty->_cache_info['insert_tags'][$_name] = array('insert', + $_name, + $smarty->_plugins['insert'][$_name][1], + $smarty->_plugins['insert'][$_name][2], + !empty($params['args']['script']) ? true : false); + } + return $smarty->_smarty_md5."{insert_cache $_arg_string}".$smarty->_smarty_md5; + } else { + if (isset($params['args']['script'])) { + $_params = array('resource_name' => $smarty->_dequote($params['args']['script'])); + require_once(SMARTY_CORE_DIR . 'core.get_php_resource.php'); + if(!smarty_core_get_php_resource($_params, $smarty)) { + return false; + } + + if ($_params['resource_type'] == 'file') { + $smarty->_include($_params['php_resource'], true); + } else { + $smarty->_eval($_params['php_resource']); + } + unset($params['args']['script']); + } + + $_funcname = $smarty->_plugins['insert'][$params['args']['name']][0]; + $_content = $_funcname($params['args'], $smarty); + if ($smarty->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $smarty->_smarty_debug_info[] = array('type' => 'insert', + 'filename' => 'insert_'.$params['args']['name'], + 'depth' => $smarty->_inclusion_depth, + 'exec_time' => smarty_core_get_microtime($_params, $smarty) - $_debug_start_time); + } + + if (!empty($params['args']["assign"])) { + $smarty->assign($params['args']["assign"], $_content); + } else { + return $_content; + } + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.smarty_include_php.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.smarty_include_php.php new file mode 100644 index 0000000..30c6e76 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.smarty_include_php.php @@ -0,0 +1,50 @@ + $params['smarty_file']); + require_once(SMARTY_CORE_DIR . 'core.get_php_resource.php'); + smarty_core_get_php_resource($_params, $smarty); + $_smarty_resource_type = $_params['resource_type']; + $_smarty_php_resource = $_params['php_resource']; + + if (!empty($params['smarty_assign'])) { + ob_start(); + if ($_smarty_resource_type == 'file') { + $smarty->_include($_smarty_php_resource, $params['smarty_once'], $params['smarty_include_vars']); + } else { + $smarty->_eval($_smarty_php_resource, $params['smarty_include_vars']); + } + $smarty->assign($params['smarty_assign'], ob_get_contents()); + ob_end_clean(); + } else { + if ($_smarty_resource_type == 'file') { + $smarty->_include($_smarty_php_resource, $params['smarty_once'], $params['smarty_include_vars']); + } else { + $smarty->_eval($_smarty_php_resource, $params['smarty_include_vars']); + } + } +} + + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_cache_file.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_cache_file.php new file mode 100644 index 0000000..fa3cdd7 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_cache_file.php @@ -0,0 +1,96 @@ +_cache_info['timestamp'] = time(); + if ($smarty->cache_lifetime > -1){ + // expiration set + $smarty->_cache_info['expires'] = $smarty->_cache_info['timestamp'] + $smarty->cache_lifetime; + } else { + // cache will never expire + $smarty->_cache_info['expires'] = -1; + } + + // collapse nocache.../nocache-tags + if (preg_match_all('!\{(/?)nocache\:[0-9a-f]{32}#\d+\}!', $params['results'], $match, PREG_PATTERN_ORDER)) { + // remove everything between every pair of outermost noache.../nocache-tags + // and replace it by a single nocache-tag + // this new nocache-tag will be replaced by dynamic contents in + // smarty_core_process_compiled_includes() on a cache-read + + $match_count = count($match[0]); + $results = preg_split('!(\{/?nocache\:[0-9a-f]{32}#\d+\})!', $params['results'], -1, PREG_SPLIT_DELIM_CAPTURE); + + $level = 0; + $j = 0; + for ($i=0, $results_count = count($results); $i < $results_count && $j < $match_count; $i++) { + if ($results[$i] == $match[0][$j]) { + // nocache tag + if ($match[1][$j]) { // closing tag + $level--; + unset($results[$i]); + } else { // opening tag + if ($level++ > 0) unset($results[$i]); + } + $j++; + } elseif ($level > 0) { + unset($results[$i]); + } + } + $params['results'] = implode('', $results); + } + $smarty->_cache_info['cache_serials'] = $smarty->_cache_serials; + + // prepend the cache header info into cache file + $_cache_info = serialize($smarty->_cache_info); + $params['results'] = strlen($_cache_info) . "\n" . $_cache_info . $params['results']; + + if (!empty($smarty->cache_handler_func)) { + // use cache_handler function + call_user_func_array($smarty->cache_handler_func, + array('write', &$smarty, &$params['results'], $params['tpl_file'], $params['cache_id'], $params['compile_id'], $smarty->_cache_info['expires'])); + } else { + // use local cache file + + if(!@is_writable($smarty->cache_dir)) { + // cache_dir not writable, see if it exists + if(!@is_dir($smarty->cache_dir)) { + $smarty->trigger_error('the $cache_dir \'' . $smarty->cache_dir . '\' does not exist, or is not a directory.', E_USER_ERROR); + return false; + } + $smarty->trigger_error('unable to write to $cache_dir \'' . realpath($smarty->cache_dir) . '\'. Be sure $cache_dir is writable by the web server user.', E_USER_ERROR); + return false; + } + + $_auto_id = $smarty->_get_auto_id($params['cache_id'], $params['compile_id']); + $_cache_file = $smarty->_get_auto_filename($smarty->cache_dir, $params['tpl_file'], $_auto_id); + $_params = array('filename' => $_cache_file, 'contents' => $params['results'], 'create_dirs' => true); + require_once(SMARTY_CORE_DIR . 'core.write_file.php'); + smarty_core_write_file($_params, $smarty); + return true; + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_include.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_include.php new file mode 100644 index 0000000..c14adb5 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_include.php @@ -0,0 +1,91 @@ +caching && \!\$this->_cache_including\)\: echo \'\{nocache\:('.$params['cache_serial'].')#(\d+)\}\'; endif;'; + $_tag_end = 'if \(\$this->caching && \!\$this->_cache_including\)\: echo \'\{/nocache\:(\\2)#(\\3)\}\'; endif;'; + + preg_match_all('!('.$_tag_start.'(.*)'.$_tag_end.')!Us', + $params['compiled_content'], $_match_source, PREG_SET_ORDER); + + // no nocache-parts found: done + if (count($_match_source)==0) return; + + // convert the matched php-code to functions + $_include_compiled = "_version.", created on ".strftime("%Y-%m-%d %H:%M:%S")."\n"; + $_include_compiled .= " compiled from " . strtr(urlencode($params['resource_name']), array('%2F'=>'/', '%3A'=>':')) . " */\n\n"; + + $_compile_path = $params['include_file_path']; + + $smarty->_cache_serials[$_compile_path] = $params['cache_serial']; + $_include_compiled .= "\$this->_cache_serials['".$_compile_path."'] = '".$params['cache_serial']."';\n\n?>"; + + $_include_compiled .= $params['plugins_code']; + $_include_compiled .= "= 5.0) ? '_smarty' : 'this'; + for ($_i = 0, $_for_max = count($_match_source); $_i < $_for_max; $_i++) { + $_match =& $_match_source[$_i]; + $source = $_match[4]; + if ($this_varname == '_smarty') { + /* rename $this to $_smarty in the sourcecode */ + $tokens = token_get_all('\n"; + + $_params = array('filename' => $_compile_path, + 'contents' => $_include_compiled, 'create_dirs' => true); + + require_once(SMARTY_CORE_DIR . 'core.write_file.php'); + smarty_core_write_file($_params, $smarty); + return true; +} + + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_resource.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_resource.php new file mode 100644 index 0000000..b902eff --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_compiled_resource.php @@ -0,0 +1,35 @@ +compile_dir)) { + // compile_dir not writable, see if it exists + if(!@is_dir($smarty->compile_dir)) { + $smarty->trigger_error('the $compile_dir \'' . $smarty->compile_dir . '\' does not exist, or is not a directory.', E_USER_ERROR); + return false; + } + $smarty->trigger_error('unable to write to $compile_dir \'' . realpath($smarty->compile_dir) . '\'. Be sure $compile_dir is writable by the web server user.', E_USER_ERROR); + return false; + } + + $_params = array('filename' => $params['compile_path'], 'contents' => $params['compiled_content'], 'create_dirs' => true); + require_once(SMARTY_CORE_DIR . 'core.write_file.php'); + smarty_core_write_file($_params, $smarty); + return true; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_file.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_file.php new file mode 100644 index 0000000..b801155 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/internals/core.write_file.php @@ -0,0 +1,61 @@ + $_dirname); + require_once(SMARTY_CORE_DIR . 'core.create_dir_structure.php'); + smarty_core_create_dir_structure($_params, $smarty); + } + + // write to tmp file, then rename it to avoid file locking race condition + $_tmp_file = tempnam($_dirname, 'wrt'); + + if (!($fd = @fopen($_tmp_file, 'wb'))) { + $_tmp_file = $_dirname . DIRECTORY_SEPARATOR . uniqid('wrt'); + if (!($fd = @fopen($_tmp_file, 'wb'))) { + $smarty->trigger_error("problem writing temporary file '$_tmp_file'"); + return false; + } + } + + fwrite($fd, $params['contents']); + fclose($fd); + + if (DIRECTORY_SEPARATOR == '\\' || !@rename($_tmp_file, $params['filename'])) { + // On platforms and filesystems that cannot overwrite with rename() + // delete the file before renaming it -- because windows always suffers + // this, it is short-circuited to avoid the initial rename() attempt + + if (file_exists($params['filename'])) + @unlink($params['filename']); +// @unlink($params['filename']); + + + + + @rename($_tmp_file, $params['filename']); + } + @chmod($params['filename'], $smarty->_file_perms); + + return true; +} + +/* vim: set expandtab: */ + +?> \ No newline at end of file diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/block.textformat.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/block.textformat.php new file mode 100644 index 0000000..8cd010a --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/block.textformat.php @@ -0,0 +1,103 @@ + + * Name: textformat
+ * Purpose: format text a certain way with preset styles + * or custom wrap/indent settings
+ * @link http://smarty.php.net/manual/en/language.function.textformat.php {textformat} + * (Smarty online manual) + * @param array + *
+ * Params:   style: string (email)
+ *           indent: integer (0)
+ *           wrap: integer (80)
+ *           wrap_char string ("\n")
+ *           indent_char: string (" ")
+ *           wrap_boundary: boolean (true)
+ * 
+ * @author Monte Ohrt + * @param string contents of the block + * @param Smarty clever simulation of a method + * @return string string $content re-formatted + */ +function smarty_block_textformat($params, $content, &$smarty) +{ + if (is_null($content)) { + return; + } + + $style = null; + $indent = 0; + $indent_first = 0; + $indent_char = ' '; + $wrap = 80; + $wrap_char = "\n"; + $wrap_cut = false; + $assign = null; + + foreach ($params as $_key => $_val) { + switch ($_key) { + case 'style': + case 'indent_char': + case 'wrap_char': + case 'assign': + $$_key = (string)$_val; + break; + + case 'indent': + case 'indent_first': + case 'wrap': + $$_key = (int)$_val; + break; + + case 'wrap_cut': + $$_key = (bool)$_val; + break; + + default: + $smarty->trigger_error("textformat: unknown attribute '$_key'"); + } + } + + if ($style == 'email') { + $wrap = 72; + } + + // split into paragraphs + $_paragraphs = preg_split('![\r\n][\r\n]!',$content); + $_output = ''; + + for($_x = 0, $_y = count($_paragraphs); $_x < $_y; $_x++) { + if ($_paragraphs[$_x] == '') { + continue; + } + // convert mult. spaces & special chars to single space + $_paragraphs[$_x] = preg_replace(array('!\s+!','!(^\s+)|(\s+$)!'), array(' ',''), $_paragraphs[$_x]); + // indent first line + if($indent_first > 0) { + $_paragraphs[$_x] = str_repeat($indent_char, $indent_first) . $_paragraphs[$_x]; + } + // wordwrap sentences + $_paragraphs[$_x] = wordwrap($_paragraphs[$_x], $wrap - $indent, $wrap_char, $wrap_cut); + // indent lines + if($indent > 0) { + $_paragraphs[$_x] = preg_replace('!^!m', str_repeat($indent_char, $indent), $_paragraphs[$_x]); + } + } + $_output = implode($wrap_char . $wrap_char, $_paragraphs); + + return $assign ? $smarty->assign($assign, $_output) : $_output; + +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/compiler.assign.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/compiler.assign.php new file mode 100644 index 0000000..abef377 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/compiler.assign.php @@ -0,0 +1,40 @@ + + * Name: assign
+ * Purpose: assign a value to a template variable + * @link http://smarty.php.net/manual/en/language.custom.functions.php#LANGUAGE.FUNCTION.ASSIGN {assign} + * (Smarty online manual) + * @author Monte Ohrt (initial author) + * @author messju mohr (conversion to compiler function) + * @param string containing var-attribute and value-attribute + * @param Smarty_Compiler + */ +function smarty_compiler_assign($tag_attrs, &$compiler) +{ + $_params = $compiler->_parse_attrs($tag_attrs); + + if (!isset($_params['var'])) { + $compiler->_syntax_error("assign: missing 'var' parameter", E_USER_WARNING); + return; + } + + if (!isset($_params['value'])) { + $compiler->_syntax_error("assign: missing 'value' parameter", E_USER_WARNING); + return; + } + + return "\$this->assign({$_params['var']}, {$_params['value']});"; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.assign_debug_info.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.assign_debug_info.php new file mode 100644 index 0000000..6540498 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.assign_debug_info.php @@ -0,0 +1,40 @@ + + * Name: assign_debug_info
+ * Purpose: assign debug info to the template
+ * @author Monte Ohrt + * @param array unused in this plugin, this plugin uses {@link Smarty::$_config}, + * {@link Smarty::$_tpl_vars} and {@link Smarty::$_smarty_debug_info} + * @param Smarty + */ +function smarty_function_assign_debug_info($params, &$smarty) +{ + $assigned_vars = $smarty->_tpl_vars; + ksort($assigned_vars); + if (@is_array($smarty->_config[0])) { + $config_vars = $smarty->_config[0]; + ksort($config_vars); + $smarty->assign("_debug_config_keys", array_keys($config_vars)); + $smarty->assign("_debug_config_vals", array_values($config_vars)); + } + + $included_templates = $smarty->_smarty_debug_info; + + $smarty->assign("_debug_keys", array_keys($assigned_vars)); + $smarty->assign("_debug_vals", array_values($assigned_vars)); + + $smarty->assign("_debug_tpls", $included_templates); +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.config_load.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.config_load.php new file mode 100644 index 0000000..db89f63 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.config_load.php @@ -0,0 +1,142 @@ + + * Name: config_load
+ * Purpose: load config file vars + * @link http://smarty.php.net/manual/en/language.function.config.load.php {config_load} + * (Smarty online manual) + * @author Monte Ohrt + * @author messju mohr (added use of resources) + * @param array Format: + *
+ * array('file' => required config file name,
+ *       'section' => optional config file section to load
+ *       'scope' => local/parent/global
+ *       'global' => overrides scope, setting to parent if true)
+ * 
+ * @param Smarty + */ +function smarty_function_config_load($params, &$smarty) +{ + if ($smarty->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $_debug_start_time = smarty_core_get_microtime($_params, $smarty); + } + + $_file = isset($params['file']) ? $smarty->_dequote($params['file']) : null; + $_section = isset($params['section']) ? $smarty->_dequote($params['section']) : null; + $_scope = isset($params['scope']) ? $smarty->_dequote($params['scope']) : 'global'; + $_global = isset($params['global']) ? $smarty->_dequote($params['global']) : false; + + if (!isset($_file) || strlen($_file) == 0) { + $smarty->trigger_error("missing 'file' attribute in config_load tag", E_USER_ERROR, __FILE__, __LINE__); + } + + if (isset($_scope)) { + if ($_scope != 'local' && + $_scope != 'parent' && + $_scope != 'global') { + $smarty->trigger_error("invalid 'scope' attribute value", E_USER_ERROR, __FILE__, __LINE__); + } + } else { + if ($_global) { + $_scope = 'parent'; + } else { + $_scope = 'local'; + } + } + + $_params = array('resource_name' => $_file, + 'resource_base_path' => $smarty->config_dir, + 'get_source' => false); + $smarty->_parse_resource_name($_params); + $_file_path = $_params['resource_type'] . ':' . $_params['resource_name']; + if (isset($_section)) + $_compile_file = $smarty->_get_compile_path($_file_path.'|'.$_section); + else + $_compile_file = $smarty->_get_compile_path($_file_path); + + if($smarty->force_compile || !file_exists($_compile_file)) { + $_compile = true; + } elseif ($smarty->compile_check) { + $_params = array('resource_name' => $_file, + 'resource_base_path' => $smarty->config_dir, + 'get_source' => false); + $_compile = $smarty->_fetch_resource_info($_params) && + $_params['resource_timestamp'] > filemtime($_compile_file); + } else { + $_compile = false; + } + + if($_compile) { + // compile config file + if(!is_object($smarty->_conf_obj)) { + require_once SMARTY_DIR . $smarty->config_class . '.class.php'; + $smarty->_conf_obj = new $smarty->config_class(); + $smarty->_conf_obj->overwrite = $smarty->config_overwrite; + $smarty->_conf_obj->booleanize = $smarty->config_booleanize; + $smarty->_conf_obj->read_hidden = $smarty->config_read_hidden; + $smarty->_conf_obj->fix_newlines = $smarty->config_fix_newlines; + } + + $_params = array('resource_name' => $_file, + 'resource_base_path' => $smarty->config_dir, + $_params['get_source'] = true); + if (!$smarty->_fetch_resource_info($_params)) { + return; + } + $smarty->_conf_obj->set_file_contents($_file, $_params['source_content']); + $_config_vars = array_merge($smarty->_conf_obj->get($_file), + $smarty->_conf_obj->get($_file, $_section)); + if(function_exists('var_export')) { + $_output = ''; + } else { + $_output = ''\\\'', '\\'=>'\\\\')) . '\'); ?>'; + } + $_params = (array('compile_path' => $_compile_file, 'compiled_content' => $_output, 'resource_timestamp' => $_params['resource_timestamp'])); + require_once(SMARTY_CORE_DIR . 'core.write_compiled_resource.php'); + smarty_core_write_compiled_resource($_params, $smarty); + } else { + include($_compile_file); + } + + if ($smarty->caching) { + $smarty->_cache_info['config'][$_file] = true; + } + + $smarty->_config[0]['vars'] = @array_merge($smarty->_config[0]['vars'], $_config_vars); + $smarty->_config[0]['files'][$_file] = true; + + if ($_scope == 'parent') { + $smarty->_config[1]['vars'] = @array_merge($smarty->_config[1]['vars'], $_config_vars); + $smarty->_config[1]['files'][$_file] = true; + } else if ($_scope == 'global') { + for ($i = 1, $for_max = count($smarty->_config); $i < $for_max; $i++) { + $smarty->_config[$i]['vars'] = @array_merge($smarty->_config[$i]['vars'], $_config_vars); + $smarty->_config[$i]['files'][$_file] = true; + } + } + + if ($smarty->debugging) { + $_params = array(); + require_once(SMARTY_CORE_DIR . 'core.get_microtime.php'); + $smarty->_smarty_debug_info[] = array('type' => 'config', + 'filename' => $_file.' ['.$_section.'] '.$_scope, + 'depth' => $smarty->_inclusion_depth, + 'exec_time' => smarty_core_get_microtime($_params, $smarty) - $_debug_start_time); + } + +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.counter.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.counter.php new file mode 100644 index 0000000..1f26db5 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.counter.php @@ -0,0 +1,80 @@ + + * Name: counter
+ * Purpose: print out a counter value + * @author Monte Ohrt + * @link http://smarty.php.net/manual/en/language.function.counter.php {counter} + * (Smarty online manual) + * @param array parameters + * @param Smarty + * @return string|null + */ +function smarty_function_counter($params, &$smarty) +{ + static $counters = array(); + + $name = (isset($params['name'])) ? $params['name'] : 'default'; + if (!isset($counters[$name])) { + $counters[$name] = array( + 'start'=>1, + 'skip'=>1, + 'direction'=>'up', + 'count'=>1 + ); + } + $counter =& $counters[$name]; + + if (isset($params['start'])) { + $counter['start'] = $counter['count'] = (int)$params['start']; + } + + if (!empty($params['assign'])) { + $counter['assign'] = $params['assign']; + } + + if (isset($counter['assign'])) { + $smarty->assign($counter['assign'], $counter['count']); + } + + if (isset($params['print'])) { + $print = (bool)$params['print']; + } else { + $print = empty($counter['assign']); + } + + if ($print) { + $retval = $counter['count']; + } else { + $retval = null; + } + + if (isset($params['skip'])) { + $counter['skip'] = $params['skip']; + } + + if (isset($params['direction'])) { + $counter['direction'] = $params['direction']; + } + + if ($counter['direction'] == "down") + $counter['count'] -= $counter['skip']; + else + $counter['count'] += $counter['skip']; + + return $retval; + +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.cycle.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.cycle.php new file mode 100644 index 0000000..fe78bb8 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.cycle.php @@ -0,0 +1,102 @@ + + * Name: cycle
+ * Date: May 3, 2002
+ * Purpose: cycle through given values
+ * Input: + * - name = name of cycle (optional) + * - values = comma separated list of values to cycle, + * or an array of values to cycle + * (this can be left out for subsequent calls) + * - reset = boolean - resets given var to true + * - print = boolean - print var or not. default is true + * - advance = boolean - whether or not to advance the cycle + * - delimiter = the value delimiter, default is "," + * - assign = boolean, assigns to template var instead of + * printed. + * + * Examples:
+ *
+ * {cycle values="#eeeeee,#d0d0d0d"}
+ * {cycle name=row values="one,two,three" reset=true}
+ * {cycle name=row}
+ * 
+ * @link http://smarty.php.net/manual/en/language.function.cycle.php {cycle} + * (Smarty online manual) + * @author Monte Ohrt + * @author credit to Mark Priatel + * @author credit to Gerard + * @author credit to Jason Sweat + * @version 1.3 + * @param array + * @param Smarty + * @return string|null + */ +function smarty_function_cycle($params, &$smarty) +{ + static $cycle_vars; + + $name = (empty($params['name'])) ? 'default' : $params['name']; + $print = (isset($params['print'])) ? (bool)$params['print'] : true; + $advance = (isset($params['advance'])) ? (bool)$params['advance'] : true; + $reset = (isset($params['reset'])) ? (bool)$params['reset'] : false; + + if (!in_array('values', array_keys($params))) { + if(!isset($cycle_vars[$name]['values'])) { + $smarty->trigger_error("cycle: missing 'values' parameter"); + return; + } + } else { + if(isset($cycle_vars[$name]['values']) + && $cycle_vars[$name]['values'] != $params['values'] ) { + $cycle_vars[$name]['index'] = 0; + } + $cycle_vars[$name]['values'] = $params['values']; + } + + $cycle_vars[$name]['delimiter'] = (isset($params['delimiter'])) ? $params['delimiter'] : ','; + + if(is_array($cycle_vars[$name]['values'])) { + $cycle_array = $cycle_vars[$name]['values']; + } else { + $cycle_array = explode($cycle_vars[$name]['delimiter'],$cycle_vars[$name]['values']); + } + + if(!isset($cycle_vars[$name]['index']) || $reset ) { + $cycle_vars[$name]['index'] = 0; + } + + if (isset($params['assign'])) { + $print = false; + $smarty->assign($params['assign'], $cycle_array[$cycle_vars[$name]['index']]); + } + + if($print) { + $retval = $cycle_array[$cycle_vars[$name]['index']]; + } else { + $retval = null; + } + + if($advance) { + if ( $cycle_vars[$name]['index'] >= count($cycle_array) -1 ) { + $cycle_vars[$name]['index'] = 0; + } else { + $cycle_vars[$name]['index']++; + } + } + + return $retval; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.debug.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.debug.php new file mode 100644 index 0000000..4345230 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.debug.php @@ -0,0 +1,35 @@ + + * Name: debug
+ * Date: July 1, 2002
+ * Purpose: popup debug window + * @link http://smarty.php.net/manual/en/language.function.debug.php {debug} + * (Smarty online manual) + * @author Monte Ohrt + * @version 1.0 + * @param array + * @param Smarty + * @return string output from {@link Smarty::_generate_debug_output()} + */ +function smarty_function_debug($params, &$smarty) +{ + if (isset($params['output'])) { + $smarty->assign('_smarty_debug_output', $params['output']); + } + require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php'); + return smarty_core_display_debug_console(null, $smarty); +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.eval.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.eval.php new file mode 100644 index 0000000..ff0472d --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.eval.php @@ -0,0 +1,49 @@ + + * Name: eval
+ * Purpose: evaluate a template variable as a template
+ * @link http://smarty.php.net/manual/en/language.function.eval.php {eval} + * (Smarty online manual) + * @author Monte Ohrt + * @param array + * @param Smarty + */ +function smarty_function_eval($params, &$smarty) +{ + + if (!isset($params['var'])) { + $smarty->trigger_error("eval: missing 'var' parameter"); + return; + } + + if($params['var'] == '') { + return; + } + + $smarty->_compile_source('evaluated template', $params['var'], $_var_compiled); + + ob_start(); + $smarty->_eval('?>' . $_var_compiled); + $_contents = ob_get_contents(); + ob_end_clean(); + + if (!empty($params['assign'])) { + $smarty->assign($params['assign'], $_contents); + } else { + return $_contents; + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.fetch.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.fetch.php new file mode 100644 index 0000000..81b1bfc --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.fetch.php @@ -0,0 +1,221 @@ + + * Name: fetch
+ * Purpose: fetch file, web or ftp data and display results + * @link http://smarty.php.net/manual/en/language.function.fetch.php {fetch} + * (Smarty online manual) + * @author Monte Ohrt + * @param array + * @param Smarty + * @return string|null if the assign parameter is passed, Smarty assigns the + * result to a template variable + */ +function smarty_function_fetch($params, &$smarty) +{ + if (empty($params['file'])) { + $smarty->_trigger_fatal_error("[plugin] parameter 'file' cannot be empty"); + return; + } + + $content = ''; + if ($smarty->security && !preg_match('!^(http|ftp)://!i', $params['file'])) { + $_params = array('resource_type' => 'file', 'resource_name' => $params['file']); + require_once(SMARTY_CORE_DIR . 'core.is_secure.php'); + if(!smarty_core_is_secure($_params, $smarty)) { + $smarty->_trigger_fatal_error('[plugin] (secure mode) fetch \'' . $params['file'] . '\' is not allowed'); + return; + } + + // fetch the file + if($fp = @fopen($params['file'],'r')) { + while(!feof($fp)) { + $content .= fgets ($fp,4096); + } + fclose($fp); + } else { + $smarty->_trigger_fatal_error('[plugin] fetch cannot read file \'' . $params['file'] . '\''); + return; + } + } else { + // not a local file + if(preg_match('!^http://!i',$params['file'])) { + // http fetch + if($uri_parts = parse_url($params['file'])) { + // set defaults + $host = $server_name = $uri_parts['host']; + $timeout = 30; + $accept = "image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */*"; + $agent = "Smarty Template Engine ".$smarty->_version; + $referer = ""; + $uri = !empty($uri_parts['path']) ? $uri_parts['path'] : '/'; + $uri .= !empty($uri_parts['query']) ? '?' . $uri_parts['query'] : ''; + $_is_proxy = false; + if(empty($uri_parts['port'])) { + $port = 80; + } else { + $port = $uri_parts['port']; + } + if(!empty($uri_parts['user'])) { + $user = $uri_parts['user']; + } + if(!empty($uri_parts['pass'])) { + $pass = $uri_parts['pass']; + } + // loop through parameters, setup headers + foreach($params as $param_key => $param_value) { + switch($param_key) { + case "file": + case "assign": + case "assign_headers": + break; + case "user": + if(!empty($param_value)) { + $user = $param_value; + } + break; + case "pass": + if(!empty($param_value)) { + $pass = $param_value; + } + break; + case "accept": + if(!empty($param_value)) { + $accept = $param_value; + } + break; + case "header": + if(!empty($param_value)) { + if(!preg_match('![\w\d-]+: .+!',$param_value)) { + $smarty->_trigger_fatal_error("[plugin] invalid header format '".$param_value."'"); + return; + } else { + $extra_headers[] = $param_value; + } + } + break; + case "proxy_host": + if(!empty($param_value)) { + $proxy_host = $param_value; + } + break; + case "proxy_port": + if(!preg_match('!\D!', $param_value)) { + $proxy_port = (int) $param_value; + } else { + $smarty->_trigger_fatal_error("[plugin] invalid value for attribute '".$param_key."'"); + return; + } + break; + case "agent": + if(!empty($param_value)) { + $agent = $param_value; + } + break; + case "referer": + if(!empty($param_value)) { + $referer = $param_value; + } + break; + case "timeout": + if(!preg_match('!\D!', $param_value)) { + $timeout = (int) $param_value; + } else { + $smarty->_trigger_fatal_error("[plugin] invalid value for attribute '".$param_key."'"); + return; + } + break; + default: + $smarty->_trigger_fatal_error("[plugin] unrecognized attribute '".$param_key."'"); + return; + } + } + if(!empty($proxy_host) && !empty($proxy_port)) { + $_is_proxy = true; + $fp = fsockopen($proxy_host,$proxy_port,$errno,$errstr,$timeout); + } else { + $fp = fsockopen($server_name,$port,$errno,$errstr,$timeout); + } + + if(!$fp) { + $smarty->_trigger_fatal_error("[plugin] unable to fetch: $errstr ($errno)"); + return; + } else { + if($_is_proxy) { + fputs($fp, 'GET ' . $params['file'] . " HTTP/1.0\r\n"); + } else { + fputs($fp, "GET $uri HTTP/1.0\r\n"); + } + if(!empty($host)) { + fputs($fp, "Host: $host\r\n"); + } + if(!empty($accept)) { + fputs($fp, "Accept: $accept\r\n"); + } + if(!empty($agent)) { + fputs($fp, "User-Agent: $agent\r\n"); + } + if(!empty($referer)) { + fputs($fp, "Referer: $referer\r\n"); + } + if(isset($extra_headers) && is_array($extra_headers)) { + foreach($extra_headers as $curr_header) { + fputs($fp, $curr_header."\r\n"); + } + } + if(!empty($user) && !empty($pass)) { + fputs($fp, "Authorization: BASIC ".base64_encode("$user:$pass")."\r\n"); + } + + fputs($fp, "\r\n"); + while(!feof($fp)) { + $content .= fgets($fp,4096); + } + fclose($fp); + $csplit = split("\r\n\r\n",$content,2); + + $content = $csplit[1]; + + if(!empty($params['assign_headers'])) { + $smarty->assign($params['assign_headers'],split("\r\n",$csplit[0])); + } + } + } else { + $smarty->_trigger_fatal_error("[plugin] unable to parse URL, check syntax"); + return; + } + } else { + // ftp fetch + if($fp = @fopen($params['file'],'r')) { + while(!feof($fp)) { + $content .= fgets ($fp,4096); + } + fclose($fp); + } else { + $smarty->_trigger_fatal_error('[plugin] fetch cannot read file \'' . $params['file'] .'\''); + return; + } + } + + } + + + if (!empty($params['assign'])) { + $smarty->assign($params['assign'],$content); + } else { + return $content; + } +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_checkboxes.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_checkboxes.php new file mode 100644 index 0000000..ed8ad7f --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_checkboxes.php @@ -0,0 +1,143 @@ + + * Type: function
+ * Name: html_checkboxes
+ * Date: 24.Feb.2003
+ * Purpose: Prints out a list of checkbox input types
+ * Input:
+ * - name (optional) - string default "checkbox" + * - values (required) - array + * - options (optional) - associative array + * - checked (optional) - array default not set + * - separator (optional) - ie
or   + * - output (optional) - the output next to each checkbox + * - assign (optional) - assign the output as an array to this variable + * Examples: + *
+ * {html_checkboxes values=$ids output=$names}
+ * {html_checkboxes values=$ids name='box' separator='
' output=$names} + * {html_checkboxes values=$ids checked=$checked separator='
' output=$names} + *
+ * @link http://smarty.php.net/manual/en/language.function.html.checkboxes.php {html_checkboxes} + * (Smarty online manual) + * @author Christopher Kvarme + * @author credits to Monte Ohrt + * @version 1.0 + * @param array + * @param Smarty + * @return string + * @uses smarty_function_escape_special_chars() + */ +function smarty_function_html_checkboxes($params, &$smarty) +{ + require_once $smarty->_get_plugin_filepath('shared','escape_special_chars'); + + $name = 'checkbox'; + $values = null; + $options = null; + $selected = null; + $separator = ''; + $labels = true; + $output = null; + + $extra = ''; + + foreach($params as $_key => $_val) { + switch($_key) { + case 'name': + case 'separator': + $$_key = $_val; + break; + + case 'labels': + $$_key = (bool)$_val; + break; + + case 'options': + $$_key = (array)$_val; + break; + + case 'values': + case 'output': + $$_key = array_values((array)$_val); + break; + + case 'checked': + case 'selected': + $selected = array_map('strval', array_values((array)$_val)); + break; + + case 'checkboxes': + $smarty->trigger_error('html_checkboxes: the use of the "checkboxes" attribute is deprecated, use "options" instead', E_USER_WARNING); + $options = (array)$_val; + break; + + case 'assign': + break; + + default: + if(!is_array($_val)) { + $extra .= ' '.$_key.'="'.smarty_function_escape_special_chars($_val).'"'; + } else { + $smarty->trigger_error("html_checkboxes: extra attribute '$_key' cannot be an array", E_USER_NOTICE); + } + break; + } + } + + if (!isset($options) && !isset($values)) + return ''; /* raise error here? */ + + settype($selected, 'array'); + $_html_result = array(); + + if (isset($options)) { + + foreach ($options as $_key=>$_val) + $_html_result[] = smarty_function_html_checkboxes_output($name, $_key, $_val, $selected, $extra, $separator, $labels); + + + } else { + foreach ($values as $_i=>$_key) { + $_val = isset($output[$_i]) ? $output[$_i] : ''; + $_html_result[] = smarty_function_html_checkboxes_output($name, $_key, $_val, $selected, $extra, $separator, $labels); + } + + } + + if(!empty($params['assign'])) { + $smarty->assign($params['assign'], $_html_result); + } else { + return implode("\n",$_html_result); + } + +} + +function smarty_function_html_checkboxes_output($name, $value, $output, $selected, $extra, $separator, $labels) { + $_output = ''; + if ($labels) $_output .= ''; + $_output .= $separator; + + return $_output; +} + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_image.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_image.php new file mode 100644 index 0000000..9abae72 --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_image.php @@ -0,0 +1,142 @@ + + * Name: html_image
+ * Date: Feb 24, 2003
+ * Purpose: format HTML tags for the image
+ * Input:
+ * - file = file (and path) of image (required) + * - height = image height (optional, default actual height) + * - width = image width (optional, default actual width) + * - basedir = base directory for absolute paths, default + * is environment variable DOCUMENT_ROOT + * - path_prefix = prefix for path output (optional, default empty) + * + * Examples: {html_image file="/images/masthead.gif"} + * Output: + * @link http://smarty.php.net/manual/en/language.function.html.image.php {html_image} + * (Smarty online manual) + * @author Monte Ohrt + * @author credits to Duda - wrote first image function + * in repository, helped with lots of functionality + * @version 1.0 + * @param array + * @param Smarty + * @return string + * @uses smarty_function_escape_special_chars() + */ +function smarty_function_html_image($params, &$smarty) +{ + require_once $smarty->_get_plugin_filepath('shared','escape_special_chars'); + + $alt = ''; + $file = ''; + $height = ''; + $width = ''; + $extra = ''; + $prefix = ''; + $suffix = ''; + $path_prefix = ''; + $server_vars = ($smarty->request_use_auto_globals) ? $_SERVER : $GLOBALS['HTTP_SERVER_VARS']; + $basedir = isset($server_vars['DOCUMENT_ROOT']) ? $server_vars['DOCUMENT_ROOT'] : ''; + foreach($params as $_key => $_val) { + switch($_key) { + case 'file': + case 'height': + case 'width': + case 'dpi': + case 'path_prefix': + case 'basedir': + $$_key = $_val; + break; + + case 'alt': + if(!is_array($_val)) { + $$_key = smarty_function_escape_special_chars($_val); + } else { + $smarty->trigger_error("html_image: extra attribute '$_key' cannot be an array", E_USER_NOTICE); + } + break; + + case 'link': + case 'href': + $prefix = ''; + $suffix = ''; + break; + + default: + if(!is_array($_val)) { + $extra .= ' '.$_key.'="'.smarty_function_escape_special_chars($_val).'"'; + } else { + $smarty->trigger_error("html_image: extra attribute '$_key' cannot be an array", E_USER_NOTICE); + } + break; + } + } + + if (empty($file)) { + $smarty->trigger_error("html_image: missing 'file' parameter", E_USER_NOTICE); + return; + } + + if (substr($file,0,1) == '/') { + $_image_path = $basedir . $file; + } else { + $_image_path = $file; + } + + if(!isset($params['width']) || !isset($params['height'])) { + if(!$_image_data = @getimagesize($_image_path)) { + if(!file_exists($_image_path)) { + $smarty->trigger_error("html_image: unable to find '$_image_path'", E_USER_NOTICE); + return; + } else if(!is_readable($_image_path)) { + $smarty->trigger_error("html_image: unable to read '$_image_path'", E_USER_NOTICE); + return; + } else { + $smarty->trigger_error("html_image: '$_image_path' is not a valid image file", E_USER_NOTICE); + return; + } + } + if ($smarty->security && + ($_params = array('resource_type' => 'file', 'resource_name' => $_image_path)) && + (require_once(SMARTY_CORE_DIR . 'core.is_secure.php')) && + (!smarty_core_is_secure($_params, $smarty)) ) { + $smarty->trigger_error("html_image: (secure) '$_image_path' not in secure directory", E_USER_NOTICE); + } + + if(!isset($params['width'])) { + $width = $_image_data[0]; + } + if(!isset($params['height'])) { + $height = $_image_data[1]; + } + + } + + if(isset($params['dpi'])) { + if(strstr($server_vars['HTTP_USER_AGENT'], 'Mac')) { + $dpi_default = 72; + } else { + $dpi_default = 96; + } + $_resize = $dpi_default/$params['dpi']; + $width = round($width * $_resize); + $height = round($height * $_resize); + } + + return $prefix . ''.$alt.'' . $suffix; +} + +/* vim: set expandtab: */ + +?> diff --git a/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_options.php b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_options.php new file mode 100644 index 0000000..cebadde --- /dev/null +++ b/sai/modules/saimod_sys_locale/wysiwyg/distribution/wysiwyg/smarty/plugins/function.html_options.php @@ -0,0 +1,122 @@ + + * Name: html_options
+ * Input:
+ * - name (optional) - string default "select" + * - values (required if no options supplied) - array + * - options (required if no values supplied) - associative array + * - selected (optional) - string default not set + * - output (required if not options supplied) - array + * Purpose: Prints the list of