]> git.bts.cx Git - cx.git/blobdiff - cx/lib/form.php
Basic admin styling
[cx.git] / cx / lib / form.php
index d5e4e5612adb698c522e26e05ddfa81b455ad6ad..dd7b60cd18f1a9bcf9d8ebe9a85911383f23a0d5 100644 (file)
@@ -1,10 +1,19 @@
 <?php
 
 function cx_form_input_sanitized($name) {
+       $input = cx_form_input_sanitized_allowing_html($name);
+
+       if ($input != null) {
+               $input = strip_tags($input);
+       }
+       
+       return $input;
+}
+
+function cx_form_input_sanitized_allowing_html($name) {
        if (array_key_exists($name, $_POST)) {
                $insecure_input = $_POST[$name];
-               $tagless_input = strip_tags($insecure_input);
-               return $tagless_input;
+               return $insecure_input;
        } else {
                return null;
        }