diff options
Diffstat (limited to 'inc')
-rw-r--r-- | inc/common.php | 22 | ||||
-rw-r--r-- | inc/template.php | 22 |
2 files changed, 22 insertions, 22 deletions
diff --git a/inc/common.php b/inc/common.php index 6f3cad2e4..8af63002c 100644 --- a/inc/common.php +++ b/inc/common.php @@ -21,6 +21,28 @@ define('RECENTS_SKIP_MINORS',4); define('RECENTS_SKIP_SUBSPACES',8); /** + * Wrapper around htmlspecialchars() + * + * @author Andreas Gohr <andi@splitbrain.org> + * @see htmlspecialchars() + */ +function hsc($string){ + return htmlspecialchars($string, ENT_QUOTES, 'UTF-8'); +} + +/** + * print a newline terminated string + * + * You can give an indention as optional parameter + * + * @author Andreas Gohr <andi@splitbrain.org> + */ +function ptln($string,$intend=0){ + for($i=0; $i<$intend; $i++) print ' '; + print"$string\n"; +} + +/** * Return info about the current document as associative * array. * diff --git a/inc/template.php b/inc/template.php index 488ce211b..bda0a7e4b 100644 --- a/inc/template.php +++ b/inc/template.php @@ -10,28 +10,6 @@ require_once(DOKU_CONF.'dokuwiki.php'); /** - * Wrapper around htmlspecialchars() - * - * @author Andreas Gohr <andi@splitbrain.org> - * @see htmlspecialchars() - */ -function hsc($string){ - return htmlspecialchars($string); -} - -/** - * print a newline terminated string - * - * You can give an indention as optional parameter - * - * @author Andreas Gohr <andi@splitbrain.org> - */ -function ptln($string,$intend=0){ - for($i=0; $i<$intend; $i++) print ' '; - print"$string\n"; -} - -/** * Returns the path to the given template, uses * default one if the custom version doesn't exist * |