Here is some basic example code:
$newUser = new User();
if ($newUser->SaveNewUser( ))
{
echo "success";
}
else
{
echo "failure";
}
Question. Can I modify the above so I instantiate a new object within an if
statement and apply a method all on one line?
Cheers
Phil
$newUser = new User();
if ($newUser->SaveNewUser( ))
{
echo "success";
}
else
{
echo "failure";
}
Question. Can I modify the above so I instantiate a new object within an if
statement and apply a method all on one line?
Cheers
Phil
Comment