I have a PHP snippet on mty view page that is outputting a table. I have this creating my first column item and wondering if/how I could make this do one thing based on user access, and another if not access allowed.
while($row=db_fetch_array($rs))
{
echo "<tr align='center'>
<td><p><a href='AE_SubTask_view.php?editid1=".$row["ID"]."'>".$row["QRID_num"] ."</a></td>
Of course there is more to this, but I want the link to go to the view page if condition 1, and if condition 2 go to the edit page.
I was thinking this might work, but something is not right.
while($row=db_fetch_array($rs))
{
echo "<tr align='center'>"
IF($_SESSION['AEjc']=='True')
{
"<td><p><a href='AE_SubTask_edit.php?editid1=".$row["ID"]."'>".$row["QRID_num"] ."</a></td>"
}ELSE{
"<td><p><a href='AE_SubTask_view.php?editid1=".$row["ID"]."'>".$row["QRID_num"] ."</a></td>"
}"