The answer you entered to the math problem is incorrect.

Does PHP wait? (no replies)

Hi!

I have a php class that validates user submited content. It goes something like this:

$var = $validate->fct($_POST['something']);


... and in my class:

function fct($var){
   //validates data
   if($noproblem){
      return $var;
   }else{
      //logout the user and exit();
   }
}


I need to be sure that the script exits when !$noproblem. I really don't know if the php waits for the function to end or if it goes on. Any help?

Reply

Please solve the math problem above and type in the result. e.g. for 1+1, type 2.