This topic is locked
[SOLVED]

 Can I have multiple else statements in after successful logon Event

6/2/2012 12:49:08 PM
PHPRunner General questions
S
scoobysteve author

I have a IF statement running in my After successful logon event which is working fine BUT I want to have more than 3 options, is it possible to runn multiple If else elseif statments in the event
I currently have
if($data['Score'] >= 200)

{

header("Location: page1.php");

}

else

{

header("Location: page2.php");

}

exit();
But I would like a 3rd page or even more like but I cant get it to work, Any help please would be appreciated
if($data['Score'] >= 200)

{

header("Location: page1.php");

}

elseif

{

header("Location: page2.php");

}

else

{

header("Location: page3.php");

}

exit();

Sergey Kornilov admin 6/2/2012

You need to add some condition after elseif
See examples in PHP manual:

http://php.net/manual/en/control-structures.elseif.php