]> git.mxchange.org Git - friendica.git/blobdiff - library/Smarty/libs/plugins/variablefilter.htmlspecialchars.php
add smarty engine, remove some obsolete zot1 stuff
[friendica.git] / library / Smarty / libs / plugins / variablefilter.htmlspecialchars.php
diff --git a/library/Smarty/libs/plugins/variablefilter.htmlspecialchars.php b/library/Smarty/libs/plugins/variablefilter.htmlspecialchars.php
new file mode 100644 (file)
index 0000000..aff711e
--- /dev/null
@@ -0,0 +1,21 @@
+<?php
+/**
+ * Smarty plugin
+ *
+ * @package Smarty
+ * @subpackage PluginsFilter
+ */
+
+/**
+ * Smarty htmlspecialchars variablefilter plugin
+ *
+ * @param string                   $source input string
+ * @param Smarty_Internal_Template $smarty Smarty object
+ * @return string filtered output
+ */
+function smarty_variablefilter_htmlspecialchars($source, $smarty)
+{
+    return htmlspecialchars($source, ENT_QUOTES, Smarty::$_CHARSET);
+}
+
+?>
\ No newline at end of file