1
theCat
XOBJ_DTYPE_EMAIL
  • 2004/5/15 10:23

  • theCat

  • Just popping in

  • Posts: 77

  • Since: 2004/2/2 2


I think there is a bug with XOBJ_DTYPE_EMAIL in object.php when this object is not required : you have an error if the email ='' and you can't store your object.

line 451
if (!preg_match("/^[_a-z0-9-]+(.[_a-z0-9-]+)*@[a-z0-9-]+([.][a-z0-9-]+)+$/i",$cleanv)) {
$this->setErrors("Invalid Email");

I think this code is better
if ($cleanv != '' && !preg_match("/^[_a-z0-9-]+(.[_a-z0-9-]+)*@[a-z0-9-]+([.][a-z0-9-]+)+$/i",$cleanv)) {
$this->setErrors("Invalid Email");

2
Mithrandir
Re: XOBJ_DTYPE_EMAIL

Thank you. Could you put it on the bugs tracker?
Then I'll see if you are right and if your solution works.

3
theCat
Re: XOBJ_DTYPE_EMAIL
  • 2004/5/15 14:19

  • theCat

  • Just popping in

  • Posts: 77

  • Since: 2004/2/2 2


Quote:
Could you put it on the bugs tracker?

Yes, I can

Login

Who's Online

417 user(s) are online (300 user(s) are browsing Support Forums)


Members: 1


Guests: 416


Runeher2,

more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits