[PHP] order of evaluation

2002-04-09 Thread Erik Price
A quick question about evaluation: I have the following line in the middle of a large if/elseif/else statement: elseif (!empty($_POST['newpassword']) !$user-set_password($_POST['newpassword'])) I am simply wondering whether or not the set_password() method will be processed if the first

Re: [PHP] order of evaluation

2002-04-09 Thread Analysis Solutions
Yo Erik: On Tue, Apr 09, 2002 at 11:39:31AM -0400, Erik Price wrote: elseif (!empty($_POST['newpassword']) !$user-set_password($_POST['newpassword'])) Your order of evaluation is correct. But, considering the password length is evaluated in the set_password() function, checking empty()

Re: [PHP] order of evaluation

2002-04-09 Thread Erik Price
On Tuesday, April 9, 2002, at 12:24 PM, Analysis Solutions wrote: Yo Erik: On Tue, Apr 09, 2002 at 11:39:31AM -0400, Erik Price wrote: elseif (!empty($_POST['newpassword']) !$user-set_password($_POST['newpassword'])) Your order of evaluation is correct. But, considering the password

Re: [PHP] order of evaluation

2002-04-09 Thread Erik Price
Hey I'm sorry Dan and everyone, I realize my mistake -- if you're curious it's in my if/elseif/else chain, I explain the problem below (scroll down): Erik On Tuesday, April 9, 2002, at 03:00 PM, Erik Price wrote: Hm. I threw in a test echo statement in the class method, to make sure