Permalink
Browse files

PARAM_ALPHA now converts to lowercase

  • Loading branch information...
1 parent c3431d2 commit 80bdfe86d539eea2cf034f8ef3047b5414261030 skodak committed Feb 3, 2005
Showing with 3 additions and 2 deletions.
  1. +3 −2 lib/moodlelib.php
View
@@ -114,8 +114,9 @@ function clean_param($param, $options) {
$param = (int)$param; // Convert to integer
}
- if ($options & PARAM_ALPHA) { // Remove everything not a-z
- $param = eregi_replace('[^a-z]', '', $param);
+ if ($options & PARAM_ALPHA) { // Remove everything not a-zA-Z, coverts to lowercase
+ $param = eregi_replace('[^a-zA-Z]', '', $param);
+ $param = strtolower($param);
}
if ($options & PARAM_ALPHANUM) { // Remove everything not a-zA-Z0-9

0 comments on commit 80bdfe8

Please sign in to comment.