本文整理汇总了PHP中set_response_mes函数的典型用法代码示例。如果您正苦于以下问题:PHP set_response_mes函数的具体用法?PHP set_response_mes怎么用?PHP set_response_mes使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了set_response_mes函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: implode
$msg .= "<table style='margin-left:20px; font-family:Arial, Helvetica, sans-serif; font-size:12px; '>\n\t\t\t\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t\t\t\t <td align='right'><strong>Shop Name :</strong></td>\n\t\t\t\t\t\t\t\t\t <td align='left' class='padding-left:10px;'>" . $shopname . "</td>\n\t\t\t\t\t\t\t\t\t </tr>\t\n\t\t\t\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t\t\t\t <td align='right'><strong>Address :</strong></td>\n\t\t\t\t\t\t\t\t\t <td align='left' class='padding-left:10px;'>" . $shop_address . "</td>\n\t\t\t\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t\t\t\t <td align='right'><strong>City :</strong></td>\n\t\t\t\t\t\t\t\t\t <td align='left' class='padding-left:10px;'>" . $cityname . "</td>\n\t\t\t\t\t\t\t\t\t </tr>\n\t\t\t\t\t\t\t\t\t <tr>\n\t\t\t\t\t\t\t\t\t <td align='right'><strong>Country :</strong></td>\n\t\t\t\t\t\t\t\t\t <td align='left' class='padding-left:10px;'>" . $countryname . "</td>\n\t\t\t\t\t\t\t\t\t </tr> \n\t\t\t\t\t\t\t\t\t </table>";
$from = SITE_EMAIL;
/* GET THE EMAIL TEMPLATE FROM THE FILE AND REPLACE THE VALUES */
$str = '';
$str = implode("", file(DOCROOT . 'themes/_base_theme/email/email_all.html'));
$str = str_replace("SITEURL", $docroot, $str);
$str = str_replace("SITELOGO", $logo, $str);
$str = str_replace("RECEIVERNAME", ucfirst($name), $str);
$str = str_replace("MESSAGE", ucfirst($msg), $str);
$str = str_replace("SITENAME", SITE_NAME, $str);
$message = $str;
$SMTP_STATUS = SMTP_STATUS;
if ($SMTP_STATUS == 1) {
include DOCUMENT_ROOT . "/system/modules/SMTP/smtp.php";
//mail send thru smtp
} else {
// To send HTML mail, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
// Additional headers
$headers .= 'From: ' . $from . '' . "\r\n";
$headers .= 'Cc: ' . $from . "\r\n";
mail($to, $subject, $message, $headers);
}
}
}
// end email function
mysql_query("update coupons_coupons set coupon_status='C',force_coupon_closed='FC' where coupon_id='{$COUPONID}'") or die(mysql_error());
set_response_mes(1, $admin_language['paymentprocessed']);
url_redirect($refid);
ob_flush();
示例2: set_response_mes
$city = $_POST['city_name'];
if (!preg_match("/^(\\+){0,1}(\\d|\\s|\\(|\\)|\\-){5,20}\$/", $mobileno)) {
set_response_mes(-1, $language['invalid_mobile_number']);
url_redirect($_SERVER['REQUEST_URI']);
}
if (!empty($mobileno)) {
$val = add_mobilesubscriber($mobileno, $city);
if ($val) {
set_response_mes(1, $language['subscribe_success']);
url_redirect($_SERVER['REQUEST_URI']);
} else {
set_response_mes(-1, $language['mobile_exits']);
url_redirect($_SERVER['REQUEST_URI']);
}
} else {
set_response_mes(-1, $language['try_again']);
url_redirect($_SERVER['REQUEST_URI']);
}
}
//get the categpry list
$category_list = mysql_query("select * from coupons_cities where status='A' order by cityname");
?>
<div class="width240 fl clr borderF2F mb20">
<div class="great_deals">
<div class="great_top fl clr">
<h1><?php
echo $language['mobile_subscription'];
?>
</h1>
</div>
示例3: mysql_query
mysql_query("update coupons_users set account_balance = account_balance+{$admin_amt} where user_role='1'");
$shop_admin_uid = $user['userid'];
$past_balance = $L_QTY0 * $per_deal_cost - $admin_amt;
$shop_admin_balance = round($past_balance, 2);
mysql_query("update coupons_users set account_balance = account_balance+{$shop_admin_balance} where userid='{$shop_admin_uid}'");
} else {
if ($shop_owner_role == 2) {
$admin_amt = $L_QTY0 * ($per_deal_cost * ADMIN_COMMISSION / 100);
//payable to admin
$admin_amt = round($admin_amt, 2);
mysql_query("update coupons_users set account_balance = account_balance+{$admin_amt} where user_role='1'");
$citymgr_amt = $L_QTY0 * ($per_deal_cost * CA_COMMISSION / 100);
//payable to city manager
$citymgr_amt = round($citymgr_amt, 2);
mysql_query("update coupons_users set account_balance = account_balance+{$citymgr_amt} where userid='{$shop_owner_userid}'");
$shop_admin_uid = $user['userid'];
$past_balance = $L_QTY0 * $per_deal_cost - ($admin_amt + $citymgr_amt);
$shop_admin_balance = round($past_balance, 2);
mysql_query("update coupons_users set account_balance = account_balance+{$shop_admin_balance} where userid='{$shop_admin_uid}'");
}
}
}
}
set_response_mes(1, $admin_language['paymentprocessed']);
} else {
mysql_query("update transaction_details set CAPTURED_ACK='Failed' where ID = '{$invoice_id}'");
set_response_mes(-1, $admin_language['paymentfailed']);
}
}
url_redirect($refid);
ob_flush();
示例4: set_response_mes
//set status in DB
if ($pay_ack["ACK"] == "Failure") {
//failure operation
set_response_mes(-1, "Request Unapproved");
url_redirect(DOCROOT . "system/modules/affiliate/admin/pay-affiliates.php");
} else {
$transaction_id = $pay_ack['TRANSACTIONID'];
mysql_query("insert into aff_payments(aff_id,date,time,sales,commission,uid) values('{$uid}',NOW(),NOW(),'{$sales}','{$amount}','{$aid}') ");
//Insert the payment details to db
mysql_query("insert into aff_archived_sales(aff_id,uid,date,time,payment,payout,ip,order_number,merchant) values('{$uid}','{$aid}',NOW(),NOW(),'{$sales}','{$amount}','{$ip}','{$transaction_id}','paypal')");
//insert payout sales details
//mysql_query("delete from aff_sales where aff_id=$uid and `approved` = '2' LIMIT 1"); // delete the sales details after payout the amount
// here send full amt to the aff user, so delete all the records from aff_sales
mysql_query("delete from aff_sales where aff_id='{$uid}' and `approved` = '2' and fund_requested='1' ");
// delete the sales details after payout the amount
set_response_mes(1, "Request Approved");
url_redirect(DOCROOT . "system/modules/affiliate/admin/pay-affiliates.php");
}
//set the response and redirect it....
}
}
}
function masspay_request($subject = '', $receiver_mail = '', $currency_code = '', $payer_id = '', $amount = '', $unique_id = '', $note = '')
{
/**
* Get required parameters from the web form for the request
*/
$emailSubject = urlencode($subject);
$receiverType = urlencode($receiver_mail);
$currency = urlencode($currency_code);
$nvpstr = '';
示例5: is_login
is_login(DOCROOT . "admin/login/");
//checking whether admin logged in or not.
$userid = $_SESSION["userid"];
$shopid = $url_arr[3];
$obj = new EditShop();
$obj->editShopDetails($shopid);
if ($_POST) {
$shopname = htmlentities($_POST['shopname'], ENT_QUOTES);
$shopaddress = htmlentities($_POST['shopaddress'], ENT_QUOTES);
$city = $_POST["city"];
$country = $_POST['country'];
$lat = htmlentities($_POST['lat'], ENT_QUOTES);
$lang = htmlentities($_POST['lang'], ENT_QUOTES);
$result = updateShop($shopid, $userid, $shopname, $shopaddress, $city, $country, $lat, $lang);
$coopon_url = DOCROOT . "admin/view/rep/shops/";
set_response_mes(1, $admin_language['changesmodified']);
url_redirect($coopon_url);
}
?>
<script type="text/javascript">
/* validation */
$(document).ready(function(){ $("#form_editshop").validate();});
</script>
<div class="form">
<div class="form_top"></div>
<div class="form_cent">
<form name="form_editshop" id="form_editshop" method="post" action="" class="coopen_form fl" >
<fieldset>
示例6: mail
$SMTP_HOST = SMTP_HOST;
$SMTP_STATUS = SMTP_STATUS;
if ($SMTP_STATUS == 1) {
include DOCUMENT_ROOT . "/system/modules/SMTP/smtp.php";
//mail send thru smtp
} else {
// To send HTML mail, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
// Additional headers
$headers .= 'From: ' . $from . '' . "\r\n";
$headers .= 'Bcc: ' . $to . '' . "\r\n";
mail($to, $subject, $message, $headers);
}
//send_email($email,$to,$subject,$mes); //call email function
set_response_mes(1, $language['thank_you_for_enquiry']);
url_redirect(DOCROOT . 'contactus.html');
}
?>
<div class="work_bottom contactus">
<form action="" name="contactus" id="contactus" method="post">
<table width="100%" border="0" cellpadding="5" cellspacing="5" class="contact_user">
<tr><td align="right" valign="top">
<label><?php
echo $language["contact_name"];
?>
:</label>
</td><td>
<input name="name" type="text" class="required nospecialchars" title="<?php
echo $language['valid_name'];
示例7: is_login
<?php
is_login(DOCROOT . "admin/login/");
//checking whether admin logged in or not.
if ($_SESSION['userrole'] == '1' || $_SESSION['userrole'] == '2' || $_SESSION['userrole'] == '3') {
?>
<?php
if ($_POST["site_mode"] == $admin_language['submit']) {
$id = $_POST["id"];
$site_in = $_POST['site_in'];
$query = "update general_settings set site_in='{$site_in}' where id='{$id}'";
mysql_query($query);
set_response_mes(1, $admin_language['site_mode_change']);
url_redirect($_SERVER['REQUEST_URI']);
}
?>
<div class="menu_container">
<!-- user info -->
<div class="menu_user">
<div class="user_detail">
<label><?php
echo $admin_language['loginas'];
?>
</label>
<a href="<?php
echo DOCROOT . 'admin/profile/';
?>
" title="<?php
echo ucfirst($_SESSION['username']);
示例8: ob_start
<?php
ob_start();
include $_SERVER['DOCUMENT_ROOT'] . '/system/includes/library.inc.php';
if ($_REQUEST['lang'] != '') {
session_start();
$_SESSION["site_language"] = $_REQUEST['lang'];
} else {
session_start();
$_SESSION["site_language"] = 'en';
}
// include language file
$lang = $_SESSION["site_language"];
if ($lang) {
include DOCUMENT_ROOT . "/system/language/" . $lang . ".php";
} else {
include DOCUMENT_ROOT . "/system/language/en.php";
}
//set_response_mes(1,$language['language_has_been_changed']);
set_response_mes(1, $language['language_changed']);
url_redirect(DOCROOT);
ob_flush();
?>
示例9: ob_start
<?php
ob_start();
session_start();
include $_SERVER['DOCUMENT_ROOT'] . '/system/includes/library.inc.php';
if ($_GET) {
$id = $_GET["id"];
$url = urldecode($_GET["rurl"]);
mysql_query("delete from discussion where discussion_id='{$id}'");
// Include language files
$lang = $_SESSION["site_language"];
if ($lang) {
include DOCUMENT_ROOT . "/system/language/" . $lang . ".php";
} else {
include DOCUMENT_ROOT . "/system/language/en.php";
}
set_response_mes(1, $language['discussion_has_been_deleted']);
url_redirect($url);
}
ob_flush();
示例10: ucfirst
<div class="fl clr mt10 ">
<span class="font14 color333"><?php
echo ucfirst(htmlspecialchars_decode($row["shopname"]));
?>
<br/></span>
<?php
echo nl2br(html_entity_decode($row["shop_address"], ENT_QUOTES));
?>
<br/>
<?php
echo nl2br(html_entity_decode($row["cityname"], ENT_QUOTES));
?>
<br/>
<?php
echo nl2br(html_entity_decode($row["countryname"], ENT_QUOTES));
?>
<br/>
</div>
<div class="clr fl" style="width:400px;">
</div>
</div>
</div>
<?php
}
} else {
set_response_mes(1, $language['cannot_print']);
url_redirect(DOCROOT . "my-coupons.html");
}
die;
示例11: htmlentities
//checking whether admin logged in or not.
if ($_POST) {
$title = htmlentities($_POST['title'], ENT_QUOTES);
$description = htmlentities($_POST['description'], ENT_QUOTES);
$meta_keywords = htmlentities($_POST['meta_keywords'], ENT_QUOTES);
$meta_description = htmlentities($_POST['meta_description'], ENT_QUOTES);
$queryString = "select * from pages where title = '{$title}' ";
$resultSet = mysql_query($queryString);
if (mysql_num_rows($resultSet) > 0) {
set_response_mes(-1, $admin_language['pageexist']);
$redirect_url = DOCROOT . 'admin/add-page/';
url_redirect($redirect_url);
} else {
$title_url = friendlyURL($title);
mysql_query("insert into pages(title,title_url,description,meta_keywords,meta_description) values ('{$title}','{$title_url}','{$description}','{$meta_keywords}','{$meta_description}')");
set_response_mes(1, $admin_language['pagecreate']);
$redirect_url = DOCROOT . 'admin/add-page/';
url_redirect($redirect_url);
}
}
?>
<script type="text/javascript">
/* validation */
$(document).ready(function(){ $("#add_page").validate();});
</script>
<script type="text/javascript">
$(document).ready(function(){
$(".toggleul_4").slideToggle();
document.getElementById("left_menubutton_4").src = "<?php
示例12: set_response_mes
if (!$sale['order_number']) {
$error = 1;
//$msg .= $gXpLang['order_number'].'<br/>';
set_response_mes(-1, $gXpLang['order_number']);
header("Location: create-commission.php");
}
if (!$error) {
$gXpAdmin->addSale($sale);
$tpl = $gXpAdmin->getEmailTemplateByKey('affiliate_new_approved_sale_generated');
$gXpAdmin->sendAffiliateMail($tpl, array((int) $sale['aff_id']));
//$msg .= $gXpLang['msg_sale_success_added'];
set_response_mes(1, $gXpLang['msg_sale_success_added']);
header("Location: commissions.php");
} else {
//$msg = $gXpLang['msg_pls_correct_fields'].":<br/> {$msg}";
set_response_mes(-1, $gXpLang['msg_pls_correct_fields']);
}
header("Location: create-commission.php");
} elseif ($sale['task'] == 'cancel') {
header("Location: index.php");
}
$months = explode('|', $gXpLang['months_name']);
$date = getdate();
$years = array(0 => '2006', 1 => '2007', 2 => '2008', 3 => '2009', 4 => '2010', 5 => '2011', 6 => '2012', 7 => '2013', 8 => '2014', 9 => '2015', 10 => '2016');
$affiliates = $gXpAdmin->getAccounts(-1);
?>
<script type="text/javascript">
/* validation */
$(document).ready(function(){ $("#create_com").validate();});
</script>
<script type="text/javascript">
示例13: session_start
session_start();
is_login(DOCROOT . "admin/login/");
//checking whether admin logged in or not.
$queryString1 = "select * from cron_time_settings where id=1 ";
$resultSet1 = mysql_query($queryString1);
$resultSet2 = mysql_query($queryString1);
if ($_POST) {
$min = $_POST['min'];
$hour = $_POST['hour'];
$day = $_POST['day'];
$month = $_POST['month'];
$day_week = $_POST['day_week'];
$queryString = "update cron_time_settings set minute='{$min}',hour='{$hour}',day_month='{$day}',month='{$month}',day_week='{$day_week}' where id=1";
$resultSet = mysql_query($queryString);
set_response_mes(1, 'Cron settings have been saved');
$redirect_url = DOCROOT . 'admin/daily-deals/';
url_redirect($redirect_url);
}
?>
<script type="text/javascript">
$(document).ready(function(){
$(".toggleul_12").slideToggle();
document.getElementById("left_menubutton_12").src = "<?php
echo DOCROOT;
?>
site-admin/images/minus_but.png";
});
</script>
<div class="form">
<div class="form_top"></div>
示例14: mail
// To send HTML mail, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
// Additional headers
$headers .= 'From: ' . $from . '' . "\r\n";
mail($to, $subject, $message, $headers);
}
set_response_mes(1, $language["password_changed"]);
url_redirect(DOCROOT . "change-password.html");
} else {
set_response_mes(-1, $language["not_matched"]);
url_redirect(DOCROOT . "change-password.html");
}
}
} else {
set_response_mes(-1, $language["not_matched"]);
url_redirect(DOCROOT . "change-password.html");
}
}
?>
<?php
include "profile_submenu.php";
?>
<h1><?php
echo $page_title;
?>
</h1>
示例15: header
header("Location: general-settings.php?s=2");
exit;
}
} elseif ($_POST['task'] == 'cancel') {
header("Location: index.php");
}
require_once 'header.php';
switch ($_GET['s']) {
case 1:
//$msg = $gXpLang['msg_configuration_saved'];
set_response_mes(1, $gXpLang['msg_configuration_saved']);
header("Location: general-settings.php");
break;
case 2:
//$msg = $gXpLang['msg_config_cannot_be_writing'];
set_response_mes(-1, $gXpLang['msg_config_cannot_be_writing']);
header("Location: general-settings.php");
$error = 'error';
break;
}
$gDesc = $gXpLang['manage_general_settings'];
$gPage = $gXpLang['general_settings'];
$gPath = 'general-settings';
$buttons = array(0 => array('name' => 'save', 'img' => $gXpConfig['xpurl'] . 'admin/images/save_f2.gif', 'text' => $gXpLang['save']));
?>
<script type="text/javascript">
/* validation */
$(document).ready(function(){ $("#general-settings").validate();});
</script>
<script type="text/javascript">
$(document).ready(function(){