I am trying to write an if statment in php but I am not sure how to redirect the user to another url on a condition.
What I am trying to do is :
if $member = $notmember
go here index.php?option=com_jumi&view=application&fileid=6&Itemid=174
else
go here index.php?option=com_jumi&view=application&fileid=6&Itemid=124
I am not sure how to redirect to another url though ?.
You could use
header. Something like this:If after the
else, you have more code, you should useexit()in order to prevent of your code to keep executing.Have a look at the PHP official website. And especially take notice to the following: