Page 1 of 1

Show link based on permission

Posted: Fri Aug 04, 2006 8:24 pm
by Eiolon
I have a link that I only want people with permission to be able to see it. I have a field in the table that is:

Code: Select all

`link` enum('N','Y') NOT NULL default 'N',
If it is set to Y then I want the user to see the link, if N then not see it. Any help would be appreciated. Thanks!

Posted: Fri Aug 04, 2006 8:41 pm
by RobertGonzalez
Select the link field in a SQL statement, read the result into a var, then compare the var and, if it evaluated to true, show it.