當前位置: 首頁>>代碼示例>>PHP>>正文


PHP refreshto函數代碼示例

本文整理匯總了PHP中refreshto函數的典型用法代碼示例。如果您正苦於以下問題:PHP refreshto函數的具體用法?PHP refreshto怎麽用?PHP refreshto使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了refreshto函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: paymsg

function paymsg($url, $msg, $notify = 'success')
{
    if (empty($_POST)) {
        refreshto($url, $msg);
    }
    exit($notify);
}
開發者ID:adi00,項目名稱:wumaproject,代碼行數:7,代碼來源:tenpay.php

示例2: olpay_end

function olpay_end($numcode)
{
    global $db, $pre, $webdb, $banktype, $pay_code, $lfjuid;
    $pay_code = str_replace('QIBO', '=', $pay_code);
    //這個符號“=”容易出問題
    if (!$pay_code) {
        showerr("數據有誤!!");
    }
    list($type, $atc_moeny, $atc_numcode, $mid, $shopmoney) = explode("\t", mymd5($pay_code, 'DE'));
    if ($atc_numcode != intval($numcode)) {
        showerr("數據被修改過!!");
    }
    //主要是針對支付寶不能單純一位數字的問題,inc/olpay/alipay.php,文件中做了修改
    $numcode = str_replace("code", "", $numcode);
    //萬能表單訂單
    if ($type == 'form') {
        $rt = $db->get_one("SELECT * FROM {$pre}olpay WHERE numcode='{$numcode}' AND `formid`='{$mid}'");
        //商城訂單
    } elseif ($type == 'module') {
        $rt = $db->get_one("SELECT * FROM {$pre}olpay WHERE numcode='{$numcode}' AND `moduleid`='{$mid}'");
        $db->query("UPDATE {$pre}shoporderuser SET ifpay='1' WHERE id='{$atc_numcode}'");
        //獎勵積分
        if ($shopmoney) {
            add_user($lfjuid, $shopmoney, '購買商品得分');
        }
    }
    if (!$rt) {
        showerr('係統中沒有您的訂單,無法完成支付!');
    }
    if ($rt['ifpay'] == 1) {
        showerr('該訂單已經支付成功!');
    }
    $db->query("UPDATE {$pre}olpay SET ifpay='1' WHERE id='{$rt['id']}'");
    refreshto("{$webdb['www_url']}/", "恭喜你支付成功", 60);
}
開發者ID:GHubgenius,項目名稱:qbbj,代碼行數:35,代碼來源:olpay.php

示例3: olpay_end

function olpay_end($numcode)
{
    global $db, $pre, $webdb, $banktype;
    $rt = $db->get_one("SELECT * FROM {$pre}olpay WHERE numcode='{$numcode}' AND `paytype`=1");
    if (!$rt) {
        showerr('係統中沒有您的充值訂單,無法完成充值!');
    }
    if ($rt['ifpay'] == 1) {
        showerr('該訂單已經充值成功!');
    }
    $db->query("UPDATE {$pre}olpay SET ifpay='1' WHERE id='{$rt['id']}'");
    $num = $rt[money] * $webdb[alipay_scale];
    add_user($rt[uid], $num, '在線充值');
    refreshto("{$webdb['www_url']}/", "恭喜你充值成功", 10);
}
開發者ID:GHubgenius,項目名稱:qbbj,代碼行數:15,代碼來源:buymoneycard.php

示例4: implode

        $postSpecial->updateData($tid);
    }
    if ($postTopic) {
        //分類主題
        $postTopic->initData();
        $postTopic->insertData($tid, $fid);
    }
    if ($postCate) {
        //團購活動
        $postCate->initData();
        $postCate->insertData($tid, $fid);
    }
    if ($postdata->getIfcheck()) {
        if ($postdata->filter->filter_weight == 3) {
            $pinfo = 'enter_words';
            $banword = implode(',', $postdata->filter->filter_word);
        } else {
            $pinfo = 'enter_thread';
        }
    } else {
        if ($postdata->filter->filter_weight == 2) {
            $banword = implode(',', $postdata->filter->filter_word);
            $pinfo = 'post_word_check';
        } elseif ($postdata->linkCheckStrategy) {
            $pinfo = 'post_link_check';
        } else {
            $pinfo = 'post_check';
        }
    }
    refreshto("read.php?tid={$tid}&page={$page}&toread=1#{$pid}", $pinfo);
}
開發者ID:adi00,項目名稱:wumaproject,代碼行數:31,代碼來源:postmodify.php

示例5: md5

            }
            $pwd = md5($pwd);
        }
        require_once R_P . 'require/bbscode.php';
        $wordsfb = L::loadClass('FilterUtil');
        if (($banword = $wordsfb->comprise($aname)) !== false) {
            Showmsg('title_wordsfb');
        }
        if (($banword = $wordsfb->comprise($aintro)) !== false) {
            Showmsg('content_wordsfb');
        }
        if ($private == 3 && !$pwd && $rt['albumpwd']) {
            $pwd = $rt['albumpwd'];
        }
        $db->update("UPDATE pw_cnalbum SET " . pwSqlSingle(array('aname' => $aname, 'aintro' => $aintro, 'private' => $private, 'albumpwd' => $pwd)) . ' WHERE aid=' . pwEscape($aid));
        refreshto("{$basename}a=own", 'operate_success');
    }
} elseif ($a == 'viewalbum') {
    define('AJAX', 1);
    define('F_M', true);
    InitGP(array('aid'));
    $aid = (int) $aid;
    empty($aid) && Showmsg('data_error');
    require_once PrintEot('m_ajax');
    ajax_footer();
} elseif ($a == 'createajax') {
    define('AJAX', 1);
    define('F_M', true);
    banUser();
    InitGP(array('job'));
    require_once PrintEot('m_ajax');
開發者ID:adi00,項目名稱:wumaproject,代碼行數:31,代碼來源:index.php

示例6: Showmsg

            Showmsg('undefined_action');
        }
        $needcur = $days * $rt['sright']['sellprice'];
        $cur = $credit->get($winduid, $rt['sright']['selltype']);
        if ($cur === false) {
            Showmsg('numerics_checkfailed');
        }
        if ($cur < $needcur) {
            Showmsg('noenough_currency');
        }
        $credit->addLog('main_buygroup', array($rt['sright']['selltype'] => -$needcur), array('uid' => $winduid, 'username' => $windid, 'ip' => $onlineip, 'gptitle' => $rt['grouptitle'], 'days' => $days));
        if (!$credit->set($winduid, $rt['sright']['selltype'], -$needcur)) {
            Showmsg('numerics_checkfailed');
        }
        $userService = L::loadClass('UserService', 'user');
        /* @var $userService PW_UserService */
        if ($options == 1) {
            if ($winddb['groupid'] == '-1') {
                $userService->update($winduid, array('groupid' => $gid));
            } else {
                $groups = $mb['groups'] ? $mb['groups'] . $winddb['groupid'] . ',' : ",{$winddb['groupid']},";
                $userService->update($winduid, array('groupid' => $gid, 'groups' => $groups));
            }
        } else {
            $groups = $mb['groups'] ? $mb['groups'] . $gid . ',' : ",{$gid},";
            $userService->update($winduid, array('groups' => $groups));
        }
        $db->pw_update("SELECT uid FROM pw_extragroups WHERE uid=" . S::sqlEscape($winduid) . " AND gid=" . S::sqlEscape($gid), "UPDATE pw_extragroups SET " . S::sqlSingle(array('togid' => $winddb['groupid'], 'startdate' => $timestamp, 'days' => $days)) . " WHERE uid=" . S::sqlEscape($winduid) . "AND gid=" . S::sqlEscape($gid), "INSERT INTO pw_extragroups SET " . S::sqlSingle(array('uid' => $winduid, 'togid' => $winddb['groupid'], 'gid' => $gid, 'startdate' => $timestamp, 'days' => $days)));
        refreshto("profile.php?action=buy", 'group_buy_success');
    }
}
開發者ID:sherlockhouse,項目名稱:aliyun,代碼行數:31,代碼來源:buy.php

示例7: while

    while ($rs = $db->fetch_array($query)) {
        $Module_db->showfield($module_DB[2]['field'], $rs, 'list');
        $rs[username] || ($rs[username] = $rs[ip]);
        $rs[posttime] = date("Y-m-d H:i:s", $rs[posttime]);
        $rs[del] = " <A HREF='?action=delete_apply&id={$rs['apply_id']}'>踢除</A>";
        $listdb[] = $rs;
    }
    $showpage = getpage('', '', "?job={$job}", $rows, $totalNum);
    require ROOT_PATH . "member/head.php";
    require Memberpath . "template/list_job_member.htm";
    require ROOT_PATH . "member/foot.php";
} elseif ($action == 'delete_apply') {
    //踢除某職位下的其中一個應聘者
    $r = $db->get_one("SELECT * FROM `{$_pre}apply` WHERE id='{$id}'");
    $rs = $db->get_one("SELECT * FROM `{$_pre}content` WHERE cid='{$r['cid']}'");
    if ($rs[uid] != $lfjuid) {
        showerr("非法踢除!");
    }
    $db->query("DELETE FROM {$_pre}apply WHERE id='{$id}'");
    refreshto($FROMURL, '踢除成功', 1);
} elseif ($action == "del") {
    //刪除某職位
    $rs = $db->get_one("SELECT * FROM `{$_pre}content` WHERE id='{$id}' AND uid={$lfjuid}");
    if (!$rs) {
        showerr("非法刪除!");
    }
    $db->query("DELETE FROM `{$_pre}content` WHERE `id` = '{$id}'");
    $db->query("DELETE FROM `{$_pre}content_1` WHERE `id` = '{$id}'");
    $db->query("DELETE FROM `{$_pre}apply` WHERE `cid` = '{$id}'");
    refreshto($FROMURL, '刪除成功', 1);
}
開發者ID:xubo245,項目名稱:liuyangzhang,代碼行數:31,代碼來源:listjob.php

示例8: while

    $min = ($page - 1) * $rows;
    $query = $db->query("SELECT * FROM {$_pre}comments WHERE uid='{$lfjuid}' ORDER BY cid DESC LIMIT {$min},{$rows}");
    while ($rs = $db->fetch_array($query)) {
        $rs[content] = preg_replace("/<([^<]+)>/is", "", $rs[content]);
        $rs[title] = get_word($rs[content], 70);
        if (!$rs[username]) {
            $detail = explode(".", $rs[ip]);
            $rs[username] = "{$detail['0']}.{$detail['1']}.{$detail['2']}.*";
        }
        $rss = $db->get_one("SELECT city_id FROM {$_pre}db WHERE id='{$rs['id']}'");
        $rs[url] = get_info_url($rs[id], $rs[fid], $rss[city_id]);
        $rs[posttime] = date("Y-m-d H:i", $rs[posttime]);
        $listdb[] = $rs;
    }
    require ROOT_PATH . "member/head.php";
    require dirname(__FILE__) . "/" . "template/comment/mylist.htm";
    require ROOT_PATH . "member/foot.php";
} elseif ($action == "del") {
    if (!$ciddb) {
        showerr("請選擇一個");
    }
    foreach ($ciddb as $key => $value) {
        $rs = $db->get_one("SELECT * FROM {$_pre}comments WHERE cid='{$value}'");
        if ($rs[uid] = $lfjuid || ($rs[cuid] = $lfjuid)) {
            $db->query("DELETE FROM {$_pre}comments WHERE cid='{$value}'");
            $_erp = $Fid_db[tableid][$rs[fid]];
            $db->query("UPDATE {$_pre}content{$_erp} SET comments=comments-1 WHERE id='{$rs['id']}'");
        }
    }
    refreshto("{$FROMURL}", "刪除成功", 1);
}
開發者ID:xubo245,項目名稱:liuyangzhang,代碼行數:31,代碼來源:comment.php

示例9: array

            $mids = array();
            foreach ($weibos as $key => $weibo) {
                $mids[] = $weibo['mid'];
            }
            $weiboService->deleteWeibos($mids);
        }
        countPosts('-1');
        $credit->runsql();
        sendMawholeMessages($msgdb);
        if ($db_ifpwcache ^ 1) {
            $db->update("DELETE FROM pw_elements WHERE type !='usersort' AND id IN(" . S::sqlImplode($selids) . ')');
        }
        //* P_unlink(D_P.'data/bbscache/c_cache.php');
        pwCache::deleteData(D_P . 'data/bbscache/c_cache.php');
        if (!defined('AJAX')) {
            refreshto("apps.php?q=group&a=thread&cyid={$cyid}", 'deltopic_success');
        } else {
            Showmsg('deltopic_success_ajax');
        }
    }
}
function checkForHeadTopic($toptype, $fid, $selForums)
{
    require_once R_P . 'require/updateforum.php';
    list($catedbs, $top_1, $top_2, $top_3) = getForumListForHeadTopic($fid);
    $topAll = '';
    if ($toptype == 0) {
        return true;
    }
    if ($toptype == 1) {
        $topAll = ',' . implode(',', array_keys((array) $top_1)) . ',';
開發者ID:sherlockhouse,項目名稱:aliyun,代碼行數:31,代碼來源:m_topicadmin.php

示例10: elseif

    }
} elseif ($action == 'del') {
    PostCheck();
    InitGP(array('selid', 'type'));
    $selids = array();
    foreach ($selid as $key => $value) {
        is_numeric($value) && ($selids[] = $value);
    }
    if ($selids) {
        $selids = pwImplode($selids);
    } else {
        Showmsg('id_error');
    }
    if ($type == 'report') {
        $db->update("DELETE FROM pw_report WHERE id IN ({$selids})");
        refreshto("forumcp.php?action=edit&type=report&fid={$fid}", 'operate_success');
    }
}
function updatecache_fd1()
{
    global $db;
    $db->update("UPDATE pw_forums SET childid='0',fupadmin=''");
    $query = $db->query("SELECT fid,forumadmin FROM pw_forums WHERE type='category' ORDER BY vieworder");
    while ($cate = $db->fetch_array($query)) {
        Add_S($cate);
        $query2 = $db->query("SELECT fid,forumadmin FROM pw_forums WHERE type='forum' AND fup=" . pwEscape($cate['fid']));
        if ($db->num_rows($query2)) {
            $havechild[] = $cate['fid'];
            while ($forum = $db->fetch_array($query2)) {
                Add_S($forum);
                $fupadmin = trim($cate['forumadmin']);
開發者ID:adi00,項目名稱:wumaproject,代碼行數:31,代碼來源:forumcp.php

示例11: array_diff

}
$tmpKeyArray = array_diff(array_keys($tucoolAttachs), (array) $contentAids);
$tmpArray = array();
foreach ((array) $tmpKeyArray as $v) {
    $tmpArray[$v] = $tucoolAttachs[$v];
}
$contentAttachs = array();
if (S::isArray($haveAids)) {
    foreach ($tucoolAttachs as $k => $v) {
        if (S::inArray($k, $haveAids)) {
            $contentAttachs[$k] = $tucoolAttachs[$k];
        }
    }
}
$tucoolAttachs = array_merge($contentAttachs, (array) $tmpArray);
!$tucoolAttachs && refreshto("read.php?tid={$tid}&ds=1", '您暫無權限查看此帖的圖片!');
// 編輯圖片信息權限
$editAttachRight = $admincheck || $read['authorid'] == $winduid ? 1 : 0;
// 回複數
if ($openIndex) {
    #高樓帖子索引
    $replyCount = 1 + $db->get_value("SELECT max(floor) FROM pw_postsfloor WHERE tid =" . S::sqlEscape($tid));
} else {
    $replyCount = $read['replies'] + 1;
}
//帖子瀏覽記錄
$readlog = str_replace(",{$tid},", ',', GetCookie('readlog'));
$readlog .= ($readlog ? '' : ',') . $tid . ',';
$readlogCount = substr_count($readlog, ',');
$readlogCount > 11 && ($readlog = preg_replace("/[\\d]+\\,/i", '', $readlog, $readlogCount - 11));
Cookie('readlog', $readlog);
開發者ID:jechiy,項目名稱:PHPWind,代碼行數:31,代碼來源:slide.php

示例12: refreshto

            refreshto($jumpUrl, $msg);
        } else {
            Showmsg('修改文章失敗');
        }
    }
} elseif ($action == 'deletepage') {
    S::gp(array('id', 'page'));
    $articleModule = $articleService->getArticleModule($id);
    if (!checkEditPurview($windid, $articleModule->columnId) && $articleModule->user != $windid) {
        Showmsg('你沒有權限編輯本欄目的文章');
    }
    $articleModule->deletePage($page);
    $articleModule->showError();
    $result = $articleService->updateArticle($articleModule);
    if ($result) {
        refreshto("{$basename}q=post&action=edit&id={$id}&page=1", 'operate_success', 2);
    } else {
        Showmsg('刪除分頁失敗');
    }
}
require cmsTemplate::printEot('post');
footer();
function initFileTypeInfo($db_uploadfiletype)
{
    $uploadfiletype = $db_uploadfiletype ? unserialize($db_uploadfiletype) : array();
    $attachAllow = pwJsonEncode($uploadfiletype);
    $imageAllow = pwJsonEncode(getAllowKeysFromArray($uploadfiletype, array('jpg', 'jpeg', 'gif', 'png', 'bmp')));
    return array($attachAllow, $imageAllow);
}
function initAttach($attachs)
{
開發者ID:sherlockhouse,項目名稱:aliyun,代碼行數:31,代碼來源:m_post.php

示例13: pingfenMsg

function pingfenMsg($msg_info)
{
    global $baseUrl, $action, $tid;
    $msg_info = getLangInfo('msg', $msg_info);
    refreshto($baseUrl . 'action=' . $action . '&selid=' . $tid . '&', $msg_info, 3);
}
開發者ID:jechiy,項目名稱:PHPWind,代碼行數:6,代碼來源:pingfen.php

示例14: Showmsg

            Showmsg('bk_credit_type_error');
        }
        $change = (int) $change;
        if (!is_numeric($change) || $change <= 0) {
            Showmsg('bk_credit_fillin_error');
        }
        $change % $jf_A[$type][0] != 0 && Showmsg('change_error');
        list($sell, $buy) = explode('_', $type);
        $credit1 = $change;
        $credit2 = intval($change / $jf_A[$type][0] * $jf_A[$type][1]);
        /*
        $db->query("LOCK TABLES pw_memberdata WRITE,pw_membercredit WRITE");
        $lockfile = D_P.'data/bbscache/lock_profile.txt';
        $fp = fopen($lockfile,'wb+');
        flock($fp,LOCK_EX);
        */
        if (procLock('credit_change', $winduid)) {
            if ($credit1 > $credit->get($winduid, $sell)) {
                procUnLock('credit_change', $winduid);
                Showmsg('bk_credit_change_error');
            }
            $credit->addLog('main_changereduce', array($sell => -$credit1), array('uid' => $winduid, 'username' => $windid, 'ip' => $onlineip, 'tocname' => $credit->cType[$buy]));
            $credit->addLog('main_changeadd', array($buy => $credit2), array('uid' => $winduid, 'username' => $windid, 'ip' => $onlineip, 'fromcname' => $credit->cType[$sell]));
            $credit->sets($winduid, array($sell => -$credit1, $buy => $credit2));
            procUnLock('credit_change', $winduid);
            //fclose($fp);
            //$db->query("UNLOCK TABLES");
        }
        refreshto('userpay.php?action=change', 'bank_creditsuccess', 1, true);
    }
}
開發者ID:sherlockhouse,項目名稱:aliyun,代碼行數:31,代碼來源:userpay.php

示例15: set_cookie

    //XXX 作為demo,臨時存放在session中,網站應該用自己安全的存儲係統來存儲這些信息
    //$_SESSION["token"]   = $result["oauth_token"];
    //$_SESSION["secret"]  = $result["oauth_token_secret"];
    //$_SESSION["openid"]  = $result["openid"];
    set_cookie('token_secret', mymd5($result["oauth_token"] . "\t" . $result["oauth_token_secret"] . "\t" . $result["openid"]), 3600);
    if ($rs = $db->get_one("SELECT * FROM {$pre}memberdata WHERE `qq_api`='{$result['openid']}'")) {
        $userDB->login($rs[username], '', 3600, true);
        $fromurl = get_cookie('qq_fromurl');
        if ($fromurl && !eregi("login\\.php", $fromurl) && !eregi("reg\\.php", $fromurl)) {
            $jumpto = $fromurl;
        } else {
            $jumpto = "{$webdb['www_url']}/";
        }
        refreshto("{$jumpto}", "QQ方式登錄成功{$uc_login_code}", 1);
    } else {
        refreshto("qq_bind.php", "QQ登錄成功,請進行帳號綁定設置", 10);
    }
    //第三方處理用戶綁定邏輯
    //將openid與第三方的帳號做關聯
    //bind_to_openid();
} else {
    //登錄前
    set_cookie('qq_fromurl', $FROMURL);
    redirect_to_login($webdb[QQ_appid], $webdb[QQ_appkey], "{$webdb['www_url']}/do/qq_login.php");
}
/**
 * @brief get a access token 
 *        rfc1738 urlencode
 * @param $appid
 * @param $appkey
 * @param $request_token
開發者ID:GHubgenius,項目名稱:qbbj,代碼行數:31,代碼來源:qq_login.php


注:本文中的refreshto函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。