diff options
author | Dries Buytaert <dries@buytaert.net> | 2003-05-13 18:36:38 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2003-05-13 18:36:38 +0000 |
commit | c2d2fb73095a32394dd95e72421aec49fa2cd6f6 (patch) | |
tree | 5d2d92a31480405b8c10c3b85927049238528242 /modules/profile.module | |
parent | 13ffd8956826fec3cd9978edf73ef67d9eb8d46e (diff) | |
download | brdo-c2d2fb73095a32394dd95e72421aec49fa2cd6f6.tar.gz brdo-c2d2fb73095a32394dd95e72421aec49fa2cd6f6.tar.bz2 |
- Fixed a typo in the PostgreSQL database scheme. Patch by Michael Frankowski.
- Fixed a typo in the MSSQL database scheme. Patch by Michael Frankowski.
- Removed dependency on "register_globals = on"! Patches by Michael Frankowski.
Notes:
+ Updated the patches to use $foo["bar"] instead of $foo['bar'].
+ Updated the INSTALL and CHANGELOG files as well.
- Tiny improvement to the "./scripts/code-clean.sh" script.
Diffstat (limited to 'modules/profile.module')
-rw-r--r-- | modules/profile.module | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/profile.module b/modules/profile.module index d09639c85..8fb6da588 100644 --- a/modules/profile.module +++ b/modules/profile.module @@ -136,7 +136,7 @@ function _profile_form($edit, $mode) { function _profile_validate($edit, $mode) { - global $profile_fields, $user, $HTTP_POST_VARS; + global $profile_fields, $user; $enabled_fields = _profile_active_fields($mode); @@ -206,19 +206,19 @@ function _profile_user_view(&$user, $mode) { } function _profile_validate_avatar(&$edit) { - global $HTTP_POST_FILES, $user; + global $user; // check that uploaded file is an image, with a max file size and max height/width unset($edit["profile_avatar"]); - if ($HTTP_POST_FILES["edit"]["name"]["profile_avatar"] == "") { + if ($_FILES["edit"]["name"]["profile_avatar"] == "") { $edit["profile_avatar"] = $user->profile_avatar; return ""; } - $image_file = $HTTP_POST_FILES["edit"]["tmp_name"]["profile_avatar"]; + $image_file = $_FILES["edit"]["tmp_name"]["profile_avatar"]; if (is_uploaded_file($image_file)) { - $extension = strtolower(strrchr($HTTP_POST_FILES["edit"]["name"]["profile_avatar"], ".")); + $extension = strtolower(strrchr($_FILES["edit"]["name"]["profile_avatar"], ".")); $size = getimagesize($image_file); list($maxwidth, $maxheight) = explode("x", variable_get("profile_avatar_dimensions", "85x85")); if ((!in_array($size[2], array(1,2,3))) || (!in_array($extension, array(".gif", ".jpg", ".png", ".jpeg")))) { |