• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP zp_loggedin函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中zp_loggedin函数的典型用法代码示例。如果您正苦于以下问题:PHP zp_loggedin函数的具体用法?PHP zp_loggedin怎么用?PHP zp_loggedin使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了zp_loggedin函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: printLoginZone

/**
 * Prints out the links for login/out, register formular if asked
 */
function printLoginZone()
{
    if (!zp_loggedin() && (function_exists('printUserLogin_out') || function_exists('printUserLogin_out') || function_exists('printRegistrationForm'))) {
        $multi = 0;
        echo '<div id="loginout" class=" push_5 grid_10">';
        if (zp_loggedin() && function_exists('printUserLogin_out')) {
            printUserLogin_out('', '', false);
            $multi++;
        }
        if (!zp_loggedin() && function_exists('printUserLogin_out')) {
            if ($multi) {
                echo ' - ';
            }
            printCustomPageURL(gettext('Login'), 'login', '', '');
            $multi++;
        }
        if (!zp_loggedin() && function_exists('printRegistrationForm')) {
            if ($multi) {
                echo ' - ';
            }
            printCustomPageURL(gettext('Register for this site'), 'register', '', '');
        }
        echo '</div>';
    }
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:28,代码来源:functions.php


示例2: printThemeFooter

function printThemeFooter()
{
    echo '<ul class="menu footer">';
    if (function_exists('printRegistrationForm') or function_exists('printUserLogin_out')) {
        if (zp_loggedin() and function_exists('printUserLogin_out')) {
            echo '<li>';
            printUserLogin_out();
            echo '</li>';
        } else {
            echo '<li><a href="' . getCustomPageURL('login') . '">';
            if (function_exists('printRegistrationForm')) {
                echo gettext('Register');
            }
            if (function_exists('printRegistrationForm') and function_exists('printUserLogin_out')) {
                echo ' / ';
            }
            if (function_exists('printUserLogin_out')) {
                echo gettext('Login');
            }
            echo '</a></li>';
        }
    }
    if (function_exists('printContactForm')) {
        echo '<li><a href="' . getCustomPageURL('contact') . '">' . gettext('Contact') . '</a></li>';
    }
    echo '</ul>';
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:27,代码来源:functions.php


示例3: admin_tabs

 static function admin_tabs($tabs)
 {
     global $_zp_current_admin_obj;
     if (zp_loggedin(ADMIN_RIGHTS) && $_zp_current_admin_obj->getID()) {
         if (isset($tabs['users']['subtabs'])) {
             $subtabs = $tabs['users']['subtabs'];
         } else {
             $subtabs = array(gettext('users') => 'admin-users.php?page=users&tab=users');
         }
         $subtabs[gettext("access")] = PLUGIN_FOLDER . '/accessThreshold/admin_tab.php?page=users&tab=access';
         ksort($subtabs, SORT_LOCALE_STRING);
         $tabs['users'] = array('text' => gettext("admin"), 'link' => WEBPATH . "/" . ZENFOLDER . '/admin-users.php?page=users&tab=users', 'subtabs' => $subtabs, 'default' => 'users');
     }
     return $tabs;
     if (zp_loggedin(ADMIN_RIGHTS)) {
         if (!isset($tabs['development'])) {
             $tabs['development'] = array('text' => gettext("development"), 'subtabs' => NULL);
         }
         $tabs['development']['subtabs'][gettext("accessThreshold")] = PLUGIN_FOLDER . '/accessThreshold/admin_tab.php?page=development&tab=accessThreshold';
         $named = array_flip($tabs['development']['subtabs']);
         natcasesort($named);
         $tabs['development']['subtabs'] = $named = array_flip($named);
         $link = array_shift($named);
         if (strpos($link, '/') !== 0) {
             // zp_core relative
             $tabs['development']['link'] = WEBPATH . '/' . ZENFOLDER . '/' . $link;
         } else {
             $tabs['development']['link'] = WEBPATH . $link;
         }
     }
     return $tabs;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:32,代码来源:accessThreshold.php


示例4: purgeOptions_admin_tabs

function purgeOptions_admin_tabs($tabs)
{
    if (zp_loggedin(OPTIONS_RIGHTS)) {
        $tabs['options']['subtabs'][gettext("purge")] = "/" . PURGEOPTIONS_FOLDER . 'purgeOptions_tab.php?page=options&tab=purge';
    }
    return $tabs;
}
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:7,代码来源:purgeOptions.php


示例5: customDisplayRights

    static function customDisplayRights()
    {
        global $_zp_admin_tab;
        if (!zp_loggedin(ADMIN_RIGHTS) && $_zp_admin_tab == 'users') {
            ?>
			<script type="text/javascript">
				// <!-- <![CDATA[
				$(document).ready(function() {
					$('select[name="showgroup"]').parent("th").remove(); 	// the "Show" dropdownn menu
					$('.box-rights').remove(); 								// Rights. (the part with all the checkboxes).
					$('.box-albums-unpadded').remove(); 					// Albums, Pages, and Categories.
					$('.notebox').remove();									// All Noteboxes
					$('label[for="admin_language_0"], ul.flags').remove(); 	// Languages
					$('td:contains("<?php 
            echo gettext("Quota");
            ?>
")').parent("tr.userextrainfo").remove(); // Display of assigned quota (if the "quota_manager" plugin is enabled).
					$('tr.userextrainfo td:contains("<?php 
            echo gettext("User group membership");
            ?>
")').next().andSelf().remove(); // "User group membership" information (if the user_groups plugin is enabled).
					$('tr.userextrainfo td:contains("<?php 
            echo gettext("Street");
            ?>
")').parent("tr.userextrainfo").remove(); // Address information.
				});
				// ]]> -->
			</script>

			<?php 
        }
    }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:32,代码来源:showNoUserRights.php


示例6: handleOptionSave

 function handleOptionSave($themename, $themealbum)
 {
     if (zp_loggedin(CODEBLOCK_RIGHTS)) {
         processCodeblockSave(0, $this);
     }
     return false;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:7,代码来源:defaultCodeblocks.php


示例7: head

 static function head()
 {
     if (!zp_loggedin(TAGS_RIGHTS)) {
         if (getOption('tagFromSearch_tagOnly')) {
             setOption('search_fields', 'tags', false);
         }
     }
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:8,代码来源:tagFromSearch.php


示例8: toolbox_gallery_extensions

function toolbox_gallery_extensions()
{
    if (zp_loggedin(ADMIN_RIGHTS | COMMENT_RIGHTS)) {
        echo "<li>";
        printLink(WEBPATH . "/" . ZENFOLDER . '/admin-comments.php', gettext("Comments"), NULL, NULL, NULL);
        echo "</li>\n";
    }
}
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:8,代码来源:filter-admin_toolbox.php


示例9: tabs

 static function tabs($tabs)
 {
     if (zp_loggedin(ADMIN_RIGHTS)) {
         $oldtabs = $tabs;
         $tabs = array();
         foreach ($oldtabs as $tab => $data) {
             if ($tab == 'logs') {
                 $tabs['clone'] = array('text' => gettext("clone"), 'link' => WEBPATH . "/" . ZENFOLDER . '/' . PLUGIN_FOLDER . '/cloneZenphoto/cloneTab.php', 'rights' => ADMIN_RIGHTS, 'subtabs' => NULL);
             }
             $tabs[$tab] = $data;
         }
     }
     return $tabs;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:14,代码来源:cloneZenphoto.php


示例10: jQueryUploadHandler_admin_tabs

function jQueryUploadHandler_admin_tabs($tabs)
{
    if (zp_loggedin(UPLOAD_RIGHTS)) {
        $me = sprintf(gettext('images (%s)'), 'jQuery');
        $mylink = 'admin-upload.php?page=upload&tab=jQuery&type=' . gettext('images');
        if (is_null($tabs['upload'])) {
            $tabs['upload'] = array('text' => gettext("upload"), 'link' => WEBPATH . "/" . ZENFOLDER . '/admin-upload.php', 'subtabs' => NULL);
        }
        $tabs['upload']['subtabs'][$me] = $mylink;
        if (zp_getcookie('uploadtype') == 'jQuery') {
            $tabs['upload']['link'] = WEBPATH . "/" . ZENFOLDER . '/' . $mylink;
        }
    }
    return $tabs;
}
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:15,代码来源:uploader_jQuery.php


示例11: filterMessage

 /**
  * The function for processing a message to see if it might be SPAM
  *       returns:
  *         0 if the message is SPAM
  *         1 if the message might be SPAM (it will be marked for moderation)
  *         2 if the message is not SPAM
  *
  * @param string $author Author field from the posting
  * @param string $email Email field from the posting
  * @param string $website Website field from the posting
  * @param string $body The text of the comment
  * @param string $receiver The object on which the post was made
  * @param string $ip the IP address of the comment poster
  *
  * @return int
  */
 function filterMessage($author, $email, $website, $body, $receiver, $ip)
 {
     if (zp_loggedin($receiver->manage_rights) || $receiver->isMyItem($receiver->manage_some_rights)) {
         //	trust "managers"
         return 2;
     }
     $strategy = getOption('Action');
     switch ($strategy) {
         case 'reject':
             return 0;
         case 'moderate':
             return 1;
     }
     return 2;
 }
开发者ID:hatone,项目名称:zenphoto-1.4.1.4,代码行数:31,代码来源:none.php


示例12: elFinder_admin_tabs

function elFinder_admin_tabs($tabs)
{
    if (zp_loggedin(FILES_RIGHTS)) {
        $me = sprintf(gettext('files (%s)'), 'elFinder');
        $mylink = PLUGIN_FOLDER . '/' . 'elFinder/filemanager.php?page=upload&tab=elFinder&type=' . gettext('files');
        if (is_null($tabs['upload'])) {
            $tabs['upload'] = array('text' => gettext("upload"), 'link' => WEBPATH . "/" . ZENFOLDER . '/admin-upload.php', 'subtabs' => NULL);
        }
        $tabs['upload']['subtabs'][$me] = $mylink;
        if (zp_getcookie('uploadtype') == 'elFinder') {
            $tabs['upload']['link'] = WEBPATH . "/" . ZENFOLDER . '/' . $mylink;
        }
    }
    return $tabs;
}
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:15,代码来源:elFinder.php


示例13: printThemeMenu

function printThemeMenu()
{
    echo '<ul id="main">';
    if (getMainSiteName() != '') {
        echo '<li class="title">' . gettext('Main site') . '</li>';
        echo '<ul>';
        echo '<li><a href="' . getMainSiteURL() . '" title="' . getMainSiteName() . '">' . getMainSiteName() . '</a></li>';
        echo '</ul>';
    }
    if (function_exists('printAlbumMenu')) {
        echo '<li class="title">' . gettext('Gallery') . '</li>';
        $temp = getGalleryTitle();
        printAlbumMenu('list', false, '', 'menu-active', 'submenu', 'menu-active', $temp, true);
    } else {
        echo '<li class="title">' . gettext('Gallery') . '</li>';
        echo '<ul>';
        echo '<li><a href="' . getGalleryIndexURL() . '" title="' . getGalleryTitle() . '">' . getGalleryTitle() . '</a></li>';
        echo '</ul>';
    }
    if (function_exists('printNewsIndexURL')) {
        echo '<li class="title">' . gettext('News blog') . '</li>';
        printAllNewsCategories("All news", FALSE, "", "menu-active");
    }
    if (function_exists("printPageMenu")) {
        echo '<li class="title">' . gettext('Pages') . '</li>';
        printPageMenu("list", "", "menu-active", "submenu", "menu-active");
    }
    echo '<li class="title">' . gettext('Stay informed') . '</li>';
    echo '<ul>';
    echo '<li><a href="' . getCustomPageURL('archive') . '">' . gettext('Archives') . '</a></li>';
    echo '</ul>';
    echo '</ul>';
    echo '<div id="login">';
    echo '<div class="title">' . gettext('Connection') . '</div>';
    if (function_exists('printUserLogin_out') and !zp_loggedin()) {
        printUserLogin_out();
    }
    echo '</div>';
    if (function_exists("printLanguageSelector")) {
        echo '<div id="languages">';
        echo '<div class="title">' . gettext('Languages') . '</div>';
        printLanguageSelector();
        echo '<div class="clear_left"></div>';
        echo '</div>';
    }
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:46,代码来源:functions.php


示例14: zp_footer

function zp_footer()
{
    ?>
<div id="credit"><?php 
    if (zp_loggedin()) {
        printUserLogin_out($before = '', $after = '| ', $showLoginForm = NULL, $logouttext = NULL, $show_user = NULL);
    } else {
        printLinkHTML(WEBPATH . '/' . ZENFOLDER . '/admin.php', 'Admin | ');
    }
    printZenphotoLink();
    ?>
 <?php 
    printVersion();
    ?>
</a> |  Using "Side Of Chili Theme" by: <a href="http://www.chilifrei.net" title="How Do You Like Your Chili?">ChiliFrei64</a></div>
<?php 
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:17,代码来源:functions.php


示例15: admin_approval_publish_object

function admin_approval_publish_object($object)
{
    $msg = '';
    if (!zp_loggedin($object->manage_rights)) {
        // not allowed to change the published status
        if (isset($object->data['show'])) {
            $show = $object->data['show'];
        } else {
            $show = 0;
        }
        $newshow = $object->getShow();
        $object->setShow($show);
        if ($newshow != $show) {
            $msg = gettext('You do not have rights to change the <em>publish</em> state.');
        }
    }
    return $msg;
}
开发者ID:hatone,项目名称:zenphoto-1.4.1.4,代码行数:18,代码来源:admin-approval.php


示例16: front_end_edit_head

function front_end_edit_head()
{
    global $_zp_current_album;
    //Note: this allows more users to edit the album than should be allowed. It is left to the exercise
    //of the user to improve this. Remember, it is not secure anyway!
    if (($rights = zp_loggedin()) & (ADMIN_RIGHTS | ALBUM_RIGHTS)) {
        if (in_context(ZP_ALBUM)) {
            $grant = $_zp_current_album->isMyItem(ALBUM_RIGHTS);
        } else {
            $grant = $rights & ADMIN_RIGHTS;
        }
        if ($grant) {
            ?>
			<script type="text/javascript" src="<?php 
            echo WEBPATH . "/" . USER_PLUGIN_FOLDER;
            ?>
/front_end_edit/jquery.editinplace.js"></script>
			<script type="text/javascript">
				// <!-- <![CDATA[
				var zpstrings = {
					/* Used in jquery.editinplace.js */
					'Save' : "<?php 
            echo gettext('Save');
            ?>
",
					'Cancel' : "<?php 
            echo gettext('Cancel');
            ?>
",
					'Saving' : "<?php 
            echo gettext('Saving');
            ?>
",
					'ClickToEdit' : "<?php 
            echo gettext('Click to edit...');
            ?>
"
				};
				// ]]> -->
			</script>
			<?php 
        }
    }
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:44,代码来源:front_end_edit.php


示例17: updateImage

/**
 * Adds user who uploaded the image to the description of the image
 *
 * @param object $image
 * @return object
 */
function updateImage($image)
{
    global $_zp_current_admin;
    if (zp_loggedin()) {
        $bt = debug_backtrace();
        foreach ($bt as $b) {
            if (isset($b['file']) && basename($b['file']) == 'admin-upload.php') {
                $newdesc = $image->getDesc();
                if (empty($newdesc)) {
                    $newdesc = gettext('Uploaded by: ') . $_zp_current_admin['name'];
                } else {
                    $newdesc .= ' (' . gettext('Uploaded by: ') . $_zp_current_admin['name'] . ')';
                }
                $image->setDesc($newdesc);
            }
        }
    }
    return $image;
}
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:25,代码来源:filter-new_objects.php


示例18: tabs

 static function tabs($tabs)
 {
     if (zp_loggedin(ADMIN_RIGHTS)) {
         if (!isset($tabs['development'])) {
             $tabs['development'] = array('text' => gettext("development"), 'subtabs' => NULL);
         }
         $tabs['development']['subtabs'][gettext("deprecated")] = PLUGIN_FOLDER . '/deprecated-functions/admin_tab.php?page=development&tab=' . gettext('deprecated');
         $named = array_flip($tabs['development']['subtabs']);
         natcasesort($named);
         $tabs['development']['subtabs'] = $named = array_flip($named);
         $link = array_shift($named);
         if (strpos($link, '/') !== 0) {
             // zp_core relative
             $tabs['development']['link'] = WEBPATH . '/' . ZENFOLDER . '/' . $link;
         } else {
             $tabs['development']['link'] = WEBPATH . $link;
         }
     }
     return $tabs;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:20,代码来源:deprecated-functions.php


示例19: admin_tabs

 static function admin_tabs($tabs)
 {
     if (zp_loggedin(ADMIN_RIGHTS)) {
         if (!isset($tabs['development'])) {
             $tabs['development'] = array('text' => gettext("development"), 'subtabs' => NULL);
         }
         $tabs['development']['subtabs'][gettext("legacyConverter")] = '/' . USER_PLUGIN_FOLDER . '/zenphotoCompatibilityPack/legacyConverter.php?page=development&tab=' . gettext('legacyConverter');
         $named = array_flip($tabs['development']['subtabs']);
         natcasesort($named);
         $tabs['development']['subtabs'] = $named = array_flip($named);
         $link = array_shift($named);
         if (strpos($link, '/') !== 0) {
             // zp_core relative
             $tabs['development']['link'] = WEBPATH . '/' . ZENFOLDER . '/' . $link;
         } else {
             $tabs['development']['link'] = WEBPATH . $link;
         }
     }
     return $tabs;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:20,代码来源:zenphotoCompatibilityPack.php


示例20: publish_object

 static function publish_object($save, $object)
 {
     global $_admin_approval_error;
     if (is_subclass_of($object, 'ThemeObject') && !zp_loggedin($object->manage_rights)) {
         // not allowed to change the published status
         //	retrieve the original value of publish details
         $data = $object->getData();
         $show = (int) @$data['show'];
         $pub = @$data['publishdate'];
         $exp = @$data['expiredate'];
         if ($object->getShow() != $show || $object->getPublishDate() != $pub || $object->getExpireDate() != $exp) {
             //	publish details have been changed, restore the original publish details
             $object->set('show', $show);
             $object->set('publishdate', $pub);
             $object->set('expiredate', $exp);
             $_admin_approval_error = gettext('You do not have rights to change the <em>publish</em> state.');
             if (is_subclass_of($object, 'CMSItems')) {
                 $_admin_approval_error = '<p class="errorbox fade-message">' . $_admin_approval_error . '</p>';
             }
         }
     }
     return $save;
 }
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:23,代码来源:admin-approval.php



注:本文中的zp_loggedin函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP zp_mail函数代码示例发布时间:2022-05-23
下一篇:
PHP zp_has_filter函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap