Joomla簡(jiǎn)單判斷用戶(hù)是否登錄的方法

字號(hào):


    這篇文章主要介紹了Joomla簡(jiǎn)單判斷用戶(hù)是否登錄的方法,涉及Joomla基于服務(wù)器端變量結(jié)合Joomla文件進(jìn)行判斷與跳轉(zhuǎn)的相關(guān)技巧,需要的朋友可以參考下
    <?php
    if (isset($_SESSION['auth']["username"]))
    { echo "Welcome <a href='index.php?option=com_user&view=user&task=edit'>" . $_SESSION['auth']["username"] . "</a>!"; }
    else
    { echo "<a href='index.php?option=com_user&view=login'>Log in</a>"; }
    ?>
    希望本文所述對(duì)大家基于joomla程序設(shè)計(jì)有所幫助。