本文整理汇总了PHP中getSettingsValue函数的典型用法代码示例。如果您正苦于以下问题:PHP getSettingsValue函数的具体用法?PHP getSettingsValue怎么用?PHP getSettingsValue使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getSettingsValue函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: getStarRatingContent
function getStarRatingContent($txtKbSearchid)
{
$user_id = $_SESSION['sess_userid'];
$kb_id = $txtKbSearchid;
$siteUrl = getSettingsValue('SiteURL');
$kbRatingExists = checkKbRatingExists($user_id, $kb_id);
//echo '<pre>'; print_r($kbRatingExists); echo '</pre>';
if ($kbRatingExists == 0) {
$classToCall = 'jqRate';
$cursorStyle = 'cursor:pointer';
} else {
$classToCall = 'jqNoRate';
$cursorStyle = 'cursor:default';
}
$kbRatingValue = getKbRatingValue($kb_id);
$str = '<div class="rate_div" >
<div class="left">' . TEXT_KNOWLEDGEBASE_RATE . ' : </div>';
for ($i = 1; $i <= 5; $i++) {
if ($i <= $kbRatingValue) {
$image = "star-yellow.png";
} else {
$image = "star-grey.png";
}
$str .= '<span class="renderRate ' . $classToCall . '" style="' . $cursorStyle . '" id="renderRate_' . $i . '" rateVal="' . $i . '" ><img style="margin-top:4px;" src="' . $siteUrl . 'images/' . $image . '" /></span>';
}
$str .= '</div>';
return $str;
}
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:28,代码来源:functions.php
示例2: priceSortSeller
function priceSortSeller($sortBy = '')
{
$sortSettings = getSettingsValue('vEnablePriceSort');
if ($sortSettings == 'Y') {
$select_status = '<div class="pcm_sort">
<script type="text/javascript">
function submitPrice(frm){
$("#"+frm).submit();
}
</script>
';
$select_status .= "<select name='txtPriceSort' id='txtPriceSort' class='sortbox' onChange = submitPrice('frmCatalog')>\n";
$select_status .= "<option value=''>Sort by price</option>\n";
$select_status .= "<option value='DESC'";
if ($sortBy == 'DESC') {
$select_status .= " selected='selected' ";
}
$select_status .= '>High to low </option>';
$select_status .= "<option value='ASC' ";
if ($sortBy == 'ASC') {
$select_status .= " selected='selected' ";
}
$select_status .= '>Low to high </option>';
$select_status .= '</select>
<div class="clear"></div></div>';
echo $select_status;
}
}
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:30,代码来源:functions.php
示例3:
$authorize_net = "";
$authorize_net_block = "none";
}
if ($txtEnableGoogleCheck == "Y") {
$google_checkout = "checked";
$google_checkout_block = "";
} else {
$google_checkout = "";
$google_checkout_block = "none";
}
if ($txtYourPayBuffer != "" || $txtYourPayCertificate != "") {
$pem_file_message = "Certificate file uploaded !!";
} else {
$pem_file_message = "Please upload certificate file !!";
}
if (getSettingsValue('enable_buyerToseller') == 'Y') {
$sellerpaymentmode = 'checked';
$parallel_block = "";
$paypalpay_block = "none";
} else {
$adminpaymentmode = 'checked';
$parallel_block = "none";
$paypalpay_block = "";
}
//checking buyer to selled db value
if (trim($BuyertoSeller2 != '') and $BuyertoSeller2 == 'Y') {
$BuyertoSeller = 'checked';
}
//end if
if ($txtEnableBluePay == 'Y') {
$blue_pay_block = 'block';
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:payment_settings.php
示例4: dateFormat
if (isset($_POST['btnSubmit'])) {
$from_date = dateFormat($_POST['txtFromDate'], "d-m-Y", "Y-m-d");
$to_date = dateFormat($_POST['txtToDate'], "d-m-Y", "Y-m-d");
$query_string = "AND o.order_date >= " . GetSQLValueString($from_date, "text") . " AND o.order_date <= " . GetSQLValueString($to_date, "text") . " ";
$query_string1 .= '&txtFromDate=' . $_POST['txtFromDate'];
$query_string1 .= '&txtToDate=' . $_POST['txtToDate'];
} else {
$query_string = "";
}
//get orders
$sql = "SELECT DISTINCT ot.* FROM " . $tableprefix . "order_tax ot\n\t\t\t\t\t\tINNER JOIN " . $tableprefix . "orders o ON ot.orderid = o.order_id\n INNER JOIN " . $tableprefix . "order_details od ON od.order_id = o.order_id\n WHERE o.vpayment_status ='C' AND od.artist_id = '" . mysql_real_escape_string($artistid) . "' " . $query_string . " ORDER BY o.order_id DESC";
//pagination
if (!isset($pagenum)) {
$pagenum = 1;
}
$limit = getSettingsValue('npagination_limit');
$page = isset($_GET['page']) ? trim($_GET['page']) : 1;
if (empty($page)) {
$page = 1;
}
$limit = 30;
$result = mysql_query($sql) or die(mysql_error());
$totalrows = mysql_num_rows($result);
$sql_qr = $sql;
$resultRows = @mysql_num_rows(mysql_query($sql_qr));
$limitvalue = ($page - 1) * $limit;
$query_string = " LIMIT {$limitvalue}, {$limit}";
$sql = $sql . $query_string;
//echo $sql;
$result = mysql_query($sql) or die(mysql_error());
$numofpages = ceil($totalrows / $limit);
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:sales_tax_report.php
示例5: getSettingsValue
?>
" height="<?php
echo $imgheight;
?>
"></a>
</div>
<br>
<!--banner display ends here-->
<?php
}
}
$google_value = getSettingsValue('enable_google');
if ($google_value == "Y") {
?>
<table cellpadding="0" cellspacing="0" width="80%">
<tr>
<td align="center">
<?php
echo stripslashes(getSettingsValue('google_adsense_value'));
?>
</td>
</tr>
</table>
<?php
}
include "includes/" . $active_template[2];
/* Bottom File Name */
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:index.php
示例6: array_map
include "../includes/session.php";
include "../includes/functions.php";
if (get_magic_quotes_gpc()) {
$_POST = array_map('stripslashes_deep', $_POST);
$_GET = array_map('stripslashes_deep', $_GET);
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
}
if (isset($_SESSION["sess_adminname"]) and $_SESSION["sess_adminname"] != "") {
$adminname = $_SESSION["sess_adminname"];
} else {
header("Location:login.php");
exit;
}
include "../includes/htmltop.php";
/*taken from the general site settings table*/
$banner_image_size = getSettingsValue('banner_size');
if (isset($_POST['add'])) {
/*check whether banner with the same name exists in the database*/
$select_banner = "SELECT * FROM " . $tableprefix . "banners WHERE LOWER(vbanner_name) = " . GetSQLValueString(strtolower($_POST['txtBannerName']), "text");
$result_banner = mysql_query($select_banner) or die(mysql_error());
if (mysql_num_rows($result_banner) > 0) {
$message = "Banner Name Already Exists !!";
} else {
$bannerfiletype = $_FILES['txtBannerImage']['type'];
$bannerfilename = $_FILES['txtBannerImage']['name'];
$bannertempname = $_FILES['txtBannerImage']['tmp_name'];
if ($_FILES['txtBannerImage']['name'][0] != "") {
if (!isValidWebImageType($bannerfiletype, $bannerfilename, $bannertempname)) {
$message .= " * Invalid Image !! Upload an image (jpg/gif/png)" . "<br>";
} else {
$imagewidth_height_type_array = explode(":", ImageTypeBanner($_FILES['txtBannerImage']['tmp_name']));
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:banneradd.php
示例7: array_map
$_GET = array_map('stripslashes_deep', $_GET);
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
}
if (isset($_SESSION["sess_userid"]) and $_SESSION["sess_userid"] != "") {
$userid = $_SESSION["sess_userid"];
} else {
header("Location:login.php");
exit;
}
/*display the active template*/
$active_template = displayTemplate();
include "includes/htmltop.php";
/* Top File Name */
include_once "includes/" . $active_template[0];
$wishCount = getUserWishCount($userid);
$enable_wishlist = getSettingsValue('vEnableWishlist');
?>
<script language="JavaScript" type="text/JavaScript">
function clickSearch()
{
document.frmFeedbacks.submit();
}
</script>
<!-- content area Right Coulumn starts-------------------------------------------------------------- -->
<div class="pcm_content_rightcolumn">
<div class="pcm_myaccount_wrapper">
<!--mainbody area start -->
<!--center content area start-->
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:myaccount.php
示例8: header
header("Location:viewcart.php");
exit;
}
} else {
header("Location:viewcart.php");
exit;
}
if (get_magic_quotes_gpc()) {
$_POST = array_map('stripslashes_deep', $_POST);
$_GET = array_map('stripslashes_deep', $_GET);
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
}
$uspsRequired_Service = array("Express Mail", "Express Mail Hold For Pickup", "Express Mail Sunday/Holiday Delivery", "Priority Mail", "Parcel Post", "Priority Mail Large Flat Rate Box", "\nPriority Mail Medium Flat Rate Box", "Priority Mail Small Flat Rate Box", "Priority Mail Flat Rate Envelope", "Media Mail", "Library Mail");
//===================Getting Currency Type=========================
$currency_attributes = displayCurrencyType();
$flatrateEnabled = getSettingsValue('enable_flatrate');
/*display the active template*/
//checking shipping gateway and doing basic settings - Santhosh
switch ($_SESSION["sessShippingMethod"]) {
case "FDXE":
case "FDXG":
include_once 'fedex/fedex.php';
$sql = "select * from " . $tableprefix . "fedexsettings ";
$rs = mysql_query($sql) or die(mysql_error());
if (mysql_num_rows($rs) > 0) {
$serviceName = array();
$row = mysql_fetch_array($rs);
$fedexaccno = stripslashes($row['FedexAccno']);
$fedexmeterno = stripslashes($row['FedexMeterno']);
$weightunits = $row['FedexWeight'];
$server = $row['FedexServer'];
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:shipping_options.php
示例9: Images
</table>
</div>
</td>
</tr>
<tr>
<td valign="top" align="left">More Images (jpg/gif/png) </td>
<td valign="top" align="left">:</td>
<td >
<?php
$moreImagesql = "SELECT nproduct_image_id, nimage_productid,\n vimage_name, vimage_description, vproduct_image_delete_status\n FROM " . $tableprefix . "product_view_images \n WHERE nimage_productid= '" . addslashes($productid) . "'";
$result = mysql_query($moreImagesql);
if (mysql_num_rows($result) != 0) {
}
$moreImageMaxLImit = getSettingsValue('more_image_limit');
if ($moreImageMaxLImit > 0) {
for ($iCount = 0; $iCount < $moreImageMaxLImit; $iCount++) {
?>
<div class="jqMoreImageContainer" style="padding:5px;border:1px solid #D3D1D1;margin:0 15px 15px 0;float:left;width:200px; background-color:#ffffff;">
<div style="width:180px;float:left;margin-bottom: 4px;"><b>More Image <?php
echo $iCount + 1;
?>
</b><span class="help"><a href="#" title="This image is shown in product details page "><img src="../images/question_mark.jpg" border="0" height="15"></a></span></div>
<input type="file" name="productMoreImage[]" />
</div>
<?php
}
}
?>
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:29,代码来源:catalog.php
示例10: mail
</td>
</tr>
</table>
</body>
</html>';
$mailsent = mail($to, $subject, $mail_send_details, $headers);
/*********************** End email section ***********************************/
}
}
//end if
//edit review
if (isset($_POST['btnGo']) && $_POST['btnGo'] == 'Edit Review') {
switch (getSettingsValue('vReview')) {
case "automatic":
$aActive = '1';
break;
default:
$aActive = '0';
break;
}
//end switch
mysql_query("update " . $tableprefix . "Review set vDes='" . $_POST["txtReview"] . "',vActive='" . $aActive . "'\n\t\t\t\t\t\t\t\twhere nUserId='" . $_SESSION["sess_userid"] . "' and nProdId='" . $_POST["pid"] . "'") or die(mysql_error());
$msg = 'Review edited successfully';
}
//end if
?>
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:28,代码来源:product_review.php
示例11: htmlentities
?>
</td>
<td align="left" valign="top"><?php
echo htmlentities($row["user_name"]);
?>
</td>
<td align="left" valign="top"><?php
echo htmlentities(stripslashes($row["product_name"]));
?>
</td>
<td align="center" valign="top"><?php
echo $act;
?>
</td>
<?php
if (getSettingsValue('vReview') == 'vendors') {
?>
<td align="left" valign="top"><?php
echo $act2;
?>
</td>
<?php
}
//end if
?>
</tr>
<?php
$i++;
}
?>
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:30,代码来源:product_reviews.php
示例12: getConnection
/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
// +----------------------------------------------------------------------+
// | PHP version 4/5 |
// +----------------------------------------------------------------------+
// | Copyright (c) 2004-2007 ARMIA INC |
// +----------------------------------------------------------------------+
// | This source file is a part of supportpro supportdesk |
// +----------------------------------------------------------------------+
// | Authors: jimmy<[email protected]> |
// | |
// +----------------------------------------------------------------------+
require_once "./includes/applicationheader.php";
include "./includes/functions/miscfunctions.php";
include "./languages/" . $_SP_language . "/tickets.php";
$conn = getConnection();
$ticketListingOrder = getSettingsValue("OldestMessageFirst");
include "../includes/docheader.php";
?>
<title><?php
echo HEADING_TICKETS;
?>
</title>
<?php
include "./includes/headsettings.php";
$var_maxposts = (int) $_SESSION["sess_maxpostperpage"];
?>
<style>
.content_search_container .rightmargin{
margin-right:0px !important;
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:tickets.php
示例13: getShippingPriceProduct
public static function getShippingPriceProduct($productid = 0, $productOptionId = 0, $userId = "", $destination_country = "", $destination_state = "", $destination_zip = "")
{
global $tableprefix;
$adminCurrency = GetAdminCurrency();
if (isCartEmpty($userId)) {
clsGenerateShippingControl::getNoShippingControl($product_option_id);
return 0;
}
if (get_magic_quotes_gpc()) {
$_POST = array_map('stripslashes_deep', $_POST);
$_GET = array_map('stripslashes_deep', $_GET);
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
}
if ($destination_country == "" && $destination_state == "" && $destination_zip == "") {
$userAddress = clsGenerateShippingControl::getuserAddress($userId);
if (count($userAddress) > 0) {
$destination_state = $userAddress['state'];
$destination_country = $userAddress['country'];
$destination_zip = $userAddress['zip'];
}
}
$uspsRequired_Service = array("Express Mail", "Express Mail Hold For Pickup", "Express Mail Sunday/Holiday Delivery", "Priority Mail", "Parcel Post", "Priority Mail Large Flat Rate Box", "\nPriority Mail Medium Flat Rate Box", "Priority Mail Small Flat Rate Box", "Priority Mail Flat Rate Envelope", "Media Mail", "Library Mail");
//===================Getting Currency Type=========================
$currency_attributes = displayCurrencyType();
$flatrateEnabled = getSettingsValue('enable_flatrate');
/*display the active template*/
//set shipping gateway and doing basic settings
include_once 'fedex/fedex.php';
$sql = "select * from " . $tableprefix . "fedexsettings ";
$rs = mysql_query($sql) or die(mysql_error());
if (mysql_num_rows($rs) > 0) {
$serviceName = array();
$row = mysql_fetch_array($rs);
$fedexaccno = stripslashes($row['FedexAccno']);
$fedexmeterno = stripslashes($row['FedexMeterno']);
$weightunits = $row['FedexWeight'];
$server = $row['FedexServer'];
$dropoff = stripslashes($row['FedexDropOff']);
$packageTypes = stripslashes($row['FedexPackage']);
$sName = $row['FedexService'];
$currency = $row['FedexCurrency'];
if ($_SESSION["sessShippingMethod"] == "FDXE") {
$sarry = $fedexService;
$shippingTitle = "Fedex Express Shipping";
} else {
$sarry = $fedexGroundService;
$shippingTitle = "Fedex Express Ground Shipping";
}
}
// end num rows check
switch ($server) {
case "test":
$fedexserver = "https://gatewaybeta.fedex.com/GatewayDC";
break;
case "production":
// change this to actual server when go on live
$fedexserver = "https://gatewaybeta.fedex.com/GatewayDC";
break;
default:
$fedexserver = "https://gatewaybeta.fedex.com/GatewayDC";
break;
}
//// check enabled shipping is usps or not
include_once "usps/xmlparser.php";
include_once 'usps/usps.php';
$shippingTitle = "USPS";
$sql = "select * from " . $tableprefix . "usps_settings ";
$rs = mysql_query($sql) or die(mysql_error());
if (mysql_num_rows($rs) > 0) {
$row = mysql_fetch_array($rs);
$uspsid = $row['username'];
$server = $row['server'];
}
// end num rows check
switch ($server) {
case "test":
$uspsserver = "http://testing.shippingapis.com/ShippingAPITest.dll";
break;
case "production":
//change this line when usps is on live
$uspsserver = "http://Production.ShippingAPIs.com/ShippingAPI.dll";
break;
default:
$uspsserver = "http://testing.shippingapis.com/ShippingAPITest.dll";
break;
}
// end switch
require_once "ups.php";
include_once "shipping.php";
include_once 'http_client.php';
$shippingTitle = "UPS";
// Shipping setting for UPS Shipping
$select_shipping_settings = "SELECT * FROM " . $tableprefix . "shipping_settings";
$result_shipping_settings = mysql_query($select_shipping_settings);
if (mysql_num_rows($result_shipping_settings) > 0) {
$rs_ship = mysql_fetch_array($result_shipping_settings);
$ups_weight = $rs_ship['nShippingweight'];
$ups_rate = $rs_ship['ups_rate'];
$ups_container = $rs_ship['container_type'];
$ups_type = $rs_ship['address_quote_method'];
//.........这里部分代码省略.........
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:101,代码来源:shipping_price_products.php
示例14:
}
}
?>
<div class="clear"></div>
</div>
<div class="clear"></div>
</div>
<div class="clear"></div>
</div>
<!-- Footer Section End -->
<div class="clear"></div>
</div>
<?php
if (getSettingsValue('enable_pinit') == 'Y') {
?>
<script type="text/javascript" src="//assets.pinterest.com/js/pinit.js"></script>
<?php
}
?>
</body>
</html>
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:footer_portfolio.php
示例15: getProductsFromAdditionalCategoryId
function getProductsFromAdditionalCategoryId($categoryString, $sellerid = '')
{
global $tableprefix;
$additionalsql = "SELECT DISTINCT ac.product_id\n FROM " . $tableprefix . "additional_category ac\n INNER JOIN " . $tableprefix . "products p ON p.product_id=ac.product_id\n INNER JOIN " . $tableprefix . "categories cat ON ac.category_id=cat.category_id\n INNER JOIN " . $tableprefix . "product_options po ON po.product_id = p.product_id AND po.default_option = 'YES'\n INNER JOIN " . $tableprefix . "artists ar ON ar.artist_id =p.product_artist_id\n WHERE ar.vapproved ='Y' AND ar.deleted='N' AND ar.plan_expired='N'\n AND ac.category_id IN('" . $categoryString . "') AND p.vapproved = 'Y' ";
if (getSettingsValue('product_listing_fee') > 0) {
$additionalsql .= " AND p.payment_status='COMPLETED' ";
}
$additionalsql .= " AND p.deleted ='N' ";
if ($sellerid != '') {
$additionalsql .= " AND ar.artist_id ='" . mysql_real_escape_string($sellerid) . "' ";
}
$resultAdditionalCategory = mysql_query($additionalsql) or die(mysql_error);
if (mysql_num_rows($resultAdditionalCategory) > 0) {
while ($rows = mysql_fetch_array($resultAdditionalCategory)) {
$productArray[] = $rows['product_id'];
}
}
return $productArray;
echo "<pre>";
print_r($productArray);
}
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:21,代码来源:functions.php
示例16: firstData
$mylphp = new firstData();
$myorder = array();
if (getSettingsValue('vyourpay_mode') == 'TEST') {
//$myorder["host"] = "208.72.248.102"; //secure.linkpt.net for Live
$myorder["host"] = "staging.linkpt.net";
$myorder["result"] = "LIVE";
} else {
$myorder["host"] = "secure.linkpt.net";
//secure.linkpt.net for Live
$myorder["result"] = "LIVE";
}
$myorder["port"] = "1129";
//##Merchantinfo
$myorder["keyfile"] = "pem/" . getSettingsValue('vyourpay_certificate_file');
# Change this to the name and location of your certificate file
$myorder["configfile"] = trim(getSettingsValue('vyourpay_storeid'));
# Change this to your store number
//## Orderoptions
$myorder["ordertype"] = "SALE";
//The type of transaction. The possible values are SALE,PREAUTH,VOID,POSTAUTH,CREDIT, CALCSHIPPING
$yearlen = strlen($txtYY);
if ($yearlen > 2) {
$CardYear = substr($txtYY, -2);
}
# card info
$myorder["cardnumber"] = $txtCCNumber;
$myorder["cardexpmonth"] = $txtMM;
$myorder["cardexpyear"] = $CardYear;
$myorder["cvmindicator"] = "provided";
$myorder["cvmvalue"] = $txtCVV2;
//## Payment
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:product-listing-payment-cc.php
示例17: getSettingsValue
<?php
//echo '<pre>'; print_r($_REQUEST); echo '</pre>';
$var_numBegin = $_GET["numBegin"];
$var_start = $_GET["start"];
$var_begin = $_GET["begin"];
$var_num = $_GET["num"];
$txtSearchVal = $_REQUEST["txtKbTitleSearch"];
$maxPageLimit = getSettingsValue('MaxPostsPerPage');
$qryopt = "";
$txtSearch = "";
$cmbSearch = "";
?>
<script type="text/javascript">
$(document).ready(function(){
$(".jqRate").live("click",function(){
var userId = "<?php
echo $_SESSION['sess_userid'];
?>
";
if(userId<=0){
alert("Please login to rate");
return;
}
});
$(".jqNoRate").live("click",function(){
alert("You have already rated this entry");
});
});
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:userkbsearchresult.php
示例18: getSettingsValue
</tr>
<tr>
<td align="center" bgcolor="#EAEAEA" class="footer">
<p> </p>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
$adminemail = getSettingsValue('site_email');
$mailsent = mail($adminemail, $subject_admin, $mail_send_details_admin, $headers);
// End
// Redirect User To View Cart Page
// Add to constant contact
if (isset($_POST['action']) && $_POST['action'] == 'checkout') {
$sql_up1 = "SELECT cart_id FROM " . $tableprefix . "cart where visitor_cart_id ='" . session_id() . "' ";
$rs_up1 = mysql_query($sql_up1) or die(mysql_error());
if (mysql_num_rows($rs_up1) > 0) {
$sql_up_cart = "UPDATE " . $tableprefix . "cart set user_id ='" . $_SESSION["sess_userid"] . "' where visitor_cart_id ='" . session_id() . "' ";
$rs_up_cart = mysql_query($sql_up_cart) or die(mysql_error());
if ($check_news == 'Y') {
$constantcontactSettings = getconstantcontactSettings();
$_SESSION['constantaction'] = 'Add Email';
$userinfo = array();
$userinfo['emailAddress'] = $txtEmail;
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:register.php
示例19: parseFloat
//alert(totalPrice.toFixed(2));return false;
$("#shipping_rate").html(rate);
//$("#ordertotal").html(parseFloat(totalPrice.toFixed(2)));
$("#amounttopay").html( parseFloat(totalPrice.toFixed(2)));
}
</script>
<div align="left" class="main_body">
<!--mainbody area start -->
<?php
if ($ddlBillingCountry == '') {
$ddlBillingCountry = 'US';
}
$enable_commentbox = getSettingsValue('enable_commentbox');
?>
<form name="frmCheckout" action="<?php
echo $_SERVER["PHP_SELF"];
?>
" method="POST">
<!-- The id of the country field(s). If more than one, seperate with spaces -->
<input type="hidden" value="shipCountrySelect billCountrySelect" name="cs_config_country_field" id="cs_config_country_field">
<input type="hidden" value="shipStateSelect billStateSelect" name="cs_config_state_field" id="cs_config_state_field">
<!-- The id of the the fields holding the default values. If more than one, seperate with spaces -->
<input type="hidden" value="shipCountryDefault billCountryDefault" name="cs_config_country_default" id="cs_config_country_default">
<input type="hidden" value="shipStateDefault billStateDefault" name="cs_config_state_default" id="cs_config_state_default">
<!-- The actual default values -->
<input type="hidden" value="<?php
echo $ddlBillingCountry;
?>
开发者ID:kevinsmasters,项目名称:purecatskillsmarketplace,代码行数:31,代码来源:checkout_shipping.php
示例20: SMTPMail
function SMTPMail($from, $to, $host, $port, $subject, $body, $attachments = "")
{
// $from=$from; /* Change this to your address like "[email protected]"; */ $sender_line=__LINE__;
// $to=""; /* Change this to your test recipient address */ $recipient_line=__LINE__;
if (strlen($from) == 0) {
die("Please set the messages sender address in line " . $sender_line . " of the script " . basename(__FILE__) . "\n");
}
if (strlen($to) == 0) {
die("Please set the messages recipient address in line " . $recipient_line . " of the script " . basename(__FILE__) . "\n");
}
$host = getSettingsValue('SMTPServer');
$port = getSettingsValue('SMTPPort');
$username = getSettingsValue('SMTPUsername');
$password = getSettingsValue('SMTPPassword');
$sslenabled = getSettingsValue('SMTPEnableSSL');
$sslstatus = $sslenabled == '1' ? 'ssl' : '';
$mail = new PHPMailer();
$mail->IsSMTP();
// telling the class to use SMTP
$mail->Host = $host;
// SMTP server
//$mail->SMTPDebug = 2; // enables SMTP debug information (for testing)
$mail->SMTPSecure = $sslstatus;
$mail->SMTPAuth = true;
// enable SMTP authentication
$mail->Port = $port;
// set the SMTP port for the GMAIL server
$mail->Username = $username;
// SMTP account username
$mail->Password = $password;
$mail->AddReplyTo($from);
$mail->SetFrom($from);
$mail->AddAddress($to);
$mail->Subject = $subject;
$mail->AltBody = '';
// Optional, comment out and test.
$mail->MsgHTML($body);
// Send mail as html.
// Mail attachments
foreach ($attachments as $key => $value) {
$split_name_url = explode("*", $value);
$mail->AddAttachment("../attachments/" . $split_name_url[0], "Attached here is " . $split_name_url[1]);
}
$mailsent = $mail->Send();
/*
$smtp=new smtp_class;
$smtp->host_name=$host; /* Change this variable to the address of the SMTP server to relay, like "smtp.myisp.com" */
//$smtp->host_port=$port; /* Change this variable to the port of the SMTP server to use, like 465 */
//$smtp->ssl=0; /* Change this variable if the SMTP server requires an secure connection using SSL */
//$smtp->localhost="localhost"; /* Your computer address */
//$smtp->direct_delivery=0; /* Set to 1 to deliver directly to the recepient SMTP server */
//$smtp->timeout=10; /* Set to the number of seconds wait for a successful connection to the SMTP server */
//$smtp->data_timeout=0; /* Set to the number seconds wait for sending or retrieving data from the SMTP server.
/* Set to 0 to use the same defined in the timeout variable */
//$smtp->debug=1; /* Set to 1 to output the communication with the SMTP server */
//$smtp->html_debug=1; /* Set to 1 to format the debug output as HTML */
//$smtp->pop3_auth_host=""; /* Set to the POP3 authentication host if your SMTP server requires prior POP3 authentication */
//$smtp->user=""; /* Set to the user name if the server requires authetication */
//$smtp->realm=""; /* Set to the authetication realm, usually the authentication user e-mail domain */
//$smtp->password=""; /* Set to the authetication password */
//$smtp->workstation=""; /* Workstation name for NTLM authentication */
//$smtp->authentication_mechanism=""; /* Specify a SASL authentication method like LOGIN, PLAIN, CRAM-MD5, NTLM, etc..
/* Leave it empty to make the class negotiate if necessary */
/*
* If you need to use the direct delivery mode and this is running under
* Windows or any other platform that does not have enabled the MX
* resolution function GetMXRR() , you need to include code that emulates
* that function so the class knows which SMTP server it should connect
* to deliver the message directly to the recipient SMTP server.
*/
//if($smtp->direct_delivery) {
//if(!function_exists("GetMXRR")) {
/*
* If possible specify in this array the address of at least on local
* DNS that may be queried from your network.
*/
//$_NAMESERVERS=array();
// include("getmxrr.php");
// }
/*
* If GetMXRR function is available but it is not functional, to use
* the direct delivery mode, you may use a replacement function.
*/
/*
else
{
$_NAMESERVERS=array();
if(count($_NAMESERVERS)==0)
Unset($_NAMESERVERS);
include("rrcompat.php");
$smtp->getmxrr="_getmxrr";
}
*/
//}
/*
if($smtp->SendMessage(
$from,
array(
$to
//.........这里部分代码省略.........
开发者ID:ACSAUruguay,项目名称:helpdesk,代码行数:101,代码来源:main_smtp.php
注:本文中的getSettingsValue函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论