Hi,
I want a variable called $options to have different values depending on if the user is an administrator, a simple user or a teacher of course with id 54. So i write
if(isadmin() or isteacher(54)) {
$options = "<a href=\"view_inkesta.php?id=".$user[5]."\" title=\"View data\"><img src=\"../user.gif\" alt=\"view\" /></a> <a href=\"edit_inkesta.php?id=".$user[5]."\" title=\"Edit data\"><img src=\"../edit.gif\" alt=\"edit\" /></a> <a href=\"delete_inkesta.php?id=".$user[5]."\" title=\"Delete data\"><img src=\"../delete.gif\" alt=\"delete\" /></a>";
} else {
$options = "<a href=\"view_inkesta.php?id=".$user[5]."\" title=\"View data\"><img src=\"../user.gif\" alt=\"view\" /></a>";
}
But it doesn't work, and if I quit the isteacher() part it works.
What happens?
Thanks a lot!
General developer forum
Problem with isteacher()
This discussion has been locked so you can no longer reply to it.