当前位置: 首页>>代码示例>>PHP>>正文


PHP CR3DCQuery::NewTournamentRequiresApproval方法代码示例

本文整理汇总了PHP中CR3DCQuery::NewTournamentRequiresApproval方法的典型用法代码示例。如果您正苦于以下问题:PHP CR3DCQuery::NewTournamentRequiresApproval方法的具体用法?PHP CR3DCQuery::NewTournamentRequiresApproval怎么用?PHP CR3DCQuery::NewTournamentRequiresApproval使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CR3DCQuery的用法示例。


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

示例1: trim

$slctsDateYear = trim($_POST['slctsDateYear']);
$txtstime = trim($_POST['txtstime']);
$txtcomments = trim($_POST['txtcomments']);
$lstTplayers = trim($_POST['lstTplayers']);
$txtadd = trim($_POST['txtadd']);
if ($txtadd != "") {
    $TID = $oR3DCQuery->CreateTournament($config, $txttname, $slcttType, $txtplayernum, $slctcpDateMonth, $slctcpDateDay, $slctcpDateYear, $txtcptime, $slctsDateMonth, $slctsDateDay, $slctsDateYear, $txtstime, $txtcomments);
    if ($TID != 0) {
        //Add the players
        for ($i = 0; $i < count($_POST['lstTplayers']); $i++) {
            if (trim($_POST['lstTplayers'][$i]) != "") {
                $oR3DCQuery->AddTournamentPlayer($config, $TID, trim($_POST['lstTplayers'][$i]));
            }
        }
    }
    if ($oR3DCQuery->NewTournamentRequiresApproval() == false) {
        $oR3DCQuery->AcceptTournamentproposal($config, $TID);
    }
    // Email admin about tournament
    include $config;
    $subject = str_replace("['site_name']", $conf['site_name'], GetStringFromStringTable("IDS_TOURNAMENTPROPOSAL_EMAIL_SUBJECT", $config));
    $aFindTag = array("['txttname']", "['slctsDateMonth']", "['slctsDateDay']", "['slctsDateYear']", "['txtstime']", "['slctcpDateMonth']", "['slctcpDateDay']", "['slctcpDateYear']", "['txtcptime']");
    $aReplaceTag = array($txttname, $slctsDateMonth, $slctsDateDay, $slctsDateYear, $txtstime, $slctcpDateMonth, $slctcpDateDay, $slctcpDateYear, $txtcptime);
    $body = str_replace($aFindTag, $aReplaceTag, GetStringFromStringTable("IDS_TOURNAMENTPROPOSAL_EMAIL_BODY", $config));
    $oR3DCQuery->SendEmail($conf['registration_email'], $conf['registration_email'], $conf['site_name'], $subject, $body);
}
// Get current time
$todaystime = date("H:i:s");
?>

<html>
开发者ID:robertohernando,项目名称:phpchess,代码行数:31,代码来源:chess_tournament_proposal.php


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