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

PHP gpc_clear_cookie函数代码示例

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

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



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

示例1: collapse_cache_token

/**
 * Cache collapse API data from the database for the current user.
 * If the collapse cookie has been set, grab the changes and resave
 * the token, or touch it otherwise.
 */
function collapse_cache_token()
{
    global $g_collapse_cache_token;
    if (!auth_is_user_authenticated() || current_user_is_anonymous()) {
        $g_collapse_cache_token = array();
        return;
    }
    if (isset($g_collapse_cache_token)) {
        return;
    }
    $t_user_id = auth_get_current_user_id();
    $t_token = token_get_value(TOKEN_COLLAPSE);
    if (!is_null($t_token)) {
        $t_data = unserialize($t_token);
    } else {
        $t_data = array();
    }
    $g_collapse_cache_token = $t_data;
    $t_cookie = gpc_get_cookie('MANTIS_collapse_settings', '');
    if (false !== $t_cookie && !is_blank($t_cookie)) {
        $t_update = false;
        $t_data = explode('|', $t_cookie);
        foreach ($t_data as $t_pair) {
            $t_pair = explode(',', $t_pair);
            if (false !== $t_pair && count($t_pair) == 2) {
                $g_collapse_cache_token[$t_pair[0]] = true == $t_pair[1];
                $t_update = true;
            }
        }
        if ($t_update) {
            $t_token = serialize($g_collapse_cache_token);
            token_set(TOKEN_COLLAPSE, $t_token, TOKEN_EXPIRY_COLLAPSE);
        } else {
            token_touch(TOKEN_COLLAPSE);
        }
        gpc_clear_cookie('MANTIS_collapse_settings');
    }
}
开发者ID:fur81,项目名称:zofaxiopeu,代码行数:43,代码来源:collapse_api.php


示例2: auth_http_set_logout_pending

/**
 *
 * @param bool $p_pending
 * @access public
 */
function auth_http_set_logout_pending($p_pending)
{
    $t_cookie_name = config_get('logout_cookie');
    if ($p_pending) {
        gpc_set_cookie($t_cookie_name, '1', false);
    } else {
        $t_cookie_path = config_get('cookie_path');
        gpc_clear_cookie($t_cookie_name, $t_cookie_path);
    }
}
开发者ID:kaos,项目名称:mantisbt,代码行数:15,代码来源:authentication_api.php


示例3: helper_clear_pref_cookies

function helper_clear_pref_cookies()
{
    gpc_clear_cookie(config_get('project_cookie'));
    gpc_clear_cookie(config_get('manage_cookie'));
}
开发者ID:amjadtbssm,项目名称:website,代码行数:5,代码来源:helper_api.php


示例4: log_event

     $t_setting_arr[FILTER_PROPERTY_SORT_DIRECTION] = $f_dir;
     break;
     # This is when we want to copy another query from the
     # database over the top of our current one
 # This is when we want to copy another query from the
 # database over the top of our current one
 case '3':
     log_event(LOG_FILTERING, 'view_all_set.php: Copy another query from database');
     $t_filter_string = filter_db_get_filter($f_source_query_id);
     # If we can use the query that we've requested,
     # grab it. We will overwrite the current one at the
     # bottom of this page
     $t_setting_arr = filter_deserialize($t_filter_string);
     if (false === $t_setting_arr) {
         # couldn't deserialize, if we were trying to use the filter, clear it and reload
         gpc_clear_cookie('view_all_cookie');
         error_proceed_url('view_all_set.php?type=0');
         trigger_error(ERROR_FILTER_TOO_OLD, ERROR);
         exit;
         # stop here
     }
     break;
     # Generalise the filter
 # Generalise the filter
 case '4':
     log_event(LOG_FILTERING, 'view_all_set.php: Generalise the filter');
     $t_setting_arr[FILTER_PROPERTY_CATEGORY] = array(META_FILTER_ANY);
     $t_setting_arr[FILTER_PROPERTY_REPORTER_ID] = array(META_FILTER_ANY);
     $t_setting_arr[FILTER_PROPERTY_HANDLER_ID] = array(META_FILTER_ANY);
     $t_setting_arr[FILTER_PROPERTY_PRODUCT_BUILD] = array(META_FILTER_ANY);
     $t_setting_arr[FILTER_PROPERTY_PRODUCT_VERSION] = array(META_FILTER_ANY);
开发者ID:nourchene-benslimane,项目名称:mantisV0,代码行数:31,代码来源:view_all_set.php



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

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

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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