Hi I am trying to modify this line of php and add two further values to it
$my_role = ( $user == "AS") ? 8 : 10;
I would like to add the values 16 and 17
I tried
$my_role = ( $user == "AS") ? 8 : 10 : 16 : 17;
but this results in a
syntax error, unexpected ':'
Can anyone help please?
UPDATE: Thanks for your comments - Yes i managed to find out this was a ternary operator and that adding further values to it was nonsensical - What are the PHP operators "?" and ":" called and what do they do?