summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorDerek Allard <derek.allard@ellislab.com>2010-07-23 14:47:34 +0200
committerDerek Allard <derek.allard@ellislab.com>2010-07-23 14:47:34 +0200
commit4433f424d7a0dd7e5863ddd5393c13be377ed6ce (patch)
treeb7815ea2a2ade24a9f2e1abd8391322d8e117811 /system
parent958543a38c2c97b0ec4c10fc9faf4f0753143880 (diff)
adding sanitize_filename() into the security helper
Diffstat (limited to 'system')
-rw-r--r--system/helpers/security_helper.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/system/helpers/security_helper.php b/system/helpers/security_helper.php
index 654cfd100..63f0e9cdb 100644
--- a/system/helpers/security_helper.php
+++ b/system/helpers/security_helper.php
@@ -44,6 +44,24 @@ if ( ! function_exists('xss_clean'))
}
}
+// ------------------------------------------------------------------------
+
+/**
+ * Sanitize Filename
+ *
+ * @access public
+ * @param string
+ * @return string
+ */
+if ( ! function_exists('sanitize_filename'))
+{
+ function sanitize_filename($filename)
+ {
+ $CI =& get_instance();
+ return $CI->security->sanitize_filename($filename);
+ }
+}
+
// --------------------------------------------------------------------
/**