Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?
- class Tx_Projectplanner_Service_AccessControlService implements t3lib_Singleton {
- public function isLoggedIn ($person = NULL) {
- if (is_object($person)) {
- if ($person->getUid() == $this->getFrontendUserUid()) {
- return TRUE;
- }
- }
- return FALSE;
- }
- public function getFrontendUserUid () {
- if ($this->hasLoggedInFrontendUser() && !empty($GLOBALS['TSFE']->fe_user->user['uid'])) {
- return intval($GLOBALS['TSFE']->fe_user->user['uid']);
- }
- return NULL;
- }
- public function hasLoggedInFrontendUser () {
- return $GLOBALS['TSFE']->loginUser === 1 ? TRUE : FALSE;
- }
- }
- ?>
Add Comment
Please, Sign In to add comment