Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: User registration - invalid email  (Read 2106 times)

0 Members and 1 Guest are viewing this topic.

Lynn

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
User registration - invalid email
« on: February 09, 2004, 06:12:55 am »

Hi all,

I've got a small problem regarding the user registration system.  Here at the University of Washington all our email addresses end in @u.washington.edu, which does not seem to sit well with Coppermine.  It's been spewing "Email address invalid" errors at anyone who registers with their UW address.

Anyone have any suggestions on how to rectify this?

Thanks!
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
User registration - invalid email
« Reply #1 on: February 09, 2004, 08:28:26 am »

the regular expression that does email validation apparently needs a redo, since it requires the alpha-numerical bits after the @ to be at least 2 characters long. Edit register.php and search for
Code: [Select]
   if (!eregi("^[_\.0-9a-z\-]+@([0-9a-z][0-9a-z-]+\.)+[a-z]{2,6}$", $email)) $error .= '<li>' . $lang_register_php['err_invalid_email'];and replace with
Code: [Select]
   if (!eregi("^[\'+\\./0-9A-Z^_\`a-z{|}~\-]+@[a-zA-Z0-9_\-]+(\.[a-zA-Z0-9_\-]+){1,3}$", $email)) $error .= '<li>' . $lang_register_php['err_invalid_email'];. There are tons of regular expressions out there that are recommended to check valid emails...

GauGau
Logged

Lynn

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
User registration - invalid email
« Reply #2 on: February 09, 2004, 08:41:02 am »

Thanks, that worked nicely!
Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 14 queries.