PHP显示按钮,如果某些值是如此,那么

I am currently programming a PHP application, and I am wondering if it is possible for a link to only show if a certain database variable is so and so.

For example, have PHP check if the value for the user currently logged in is "Admin" under the "Rank" variable in the table, and if it is, display the link. If not, don't show anything.

Many thanks, and if anyone is confused, I'm willing to give more details.

Good thing about PHP is that you can merge HTML & PHP code both and here is your answer:

    <?php if('databaseField' === 'value to compare'){ ?>
         HTML LINK TAG
    <?php } ?>

use === instead of == because you want to match your session value with database value and in case of login too. so for security purpose use ===. it will check type of both variable as well as value.

Feel free to ask for any doubt here.