Example #1
0
    $_SESSION['mobilecode'] = $mobilecode;
    //保存在session中
    //发送验证码
    //echo $mobilecode;
    if (!empty($mobile)) {
        echo $mobilecode;
    } else {
        if (!empty($email)) {
            echo $mobilecode;
        }
    }
}
//商品详情 社区展示
if ($a == 'showcommunity') {
    $v = isset($value) ? $value : '0';
    $community = MysqlRowSelect('lgsc_community', 'id,title', "`address_city`={$v} and checkinfo='true' ORDER BY id desc");
    if ($community == -1) {
        echo 'null';
        exit;
    }
    echo '选择社区:<select id="community" >';
    echo '<option value="-1" >请选择</option>';
    for ($i = 0, $n = count($community); $i < $n; $i++) {
        echo '<option value="' . $community[$i]['id'] . '" >' . $community[$i]['title'] . '</potion>';
    }
    echo '</select> <span style="color:red"></span>';
}
//商品详情 判断是否可以配送
if ($a == 'issendcommunity') {
    $v = isset($value) ? $value : '0';
    $shopid = isset($shopid) ? $shopid : '0';
Example #2
0
<?php

set_time_limit(30);
//无限请求超时时间
require_once dirname(dirname(__FILE__)) . '/Common/index.php';
$uid = post('uid');
$time = time() - 60 * 5;
$socket = MysqlRowSelect('lgsc_socket', '*', " (  touserid = '{$user['userid']}'  and userid = '{$uid}' )  and state = '0' order by createTime asc");
$issocket = MysqlOneSelect('lgsc_socket', '*', "touserid = '{$uid}' and state = '0' ");
if ($socket == '-1') {
    exit;
} else {
    $write = '';
    for ($i = 0, $n = count($socket); $i < $n; $i++) {
        MysqlOneExc('lgsc_socket', 'state=1', 'update', "id=" . $socket[$i]['id']);
        $member = MysqlOneSelect('lgsc_member', 'avatar,username,cnname', "id=" . $socket[$i]['userid']);
        $shop = MysqlOneSelect('lgsc_shops', 'shopname,shop_username', "userid=" . $socket[$i]['userid']);
        if ($shop != -1) {
            $name = $shop['shopname'] . "-" . $member['cnname'];
        } else {
            $name = $member['username'];
        }
        if ($socket[$i]['touserid'] != $user['userid']) {
            $write .= '<div class="im-item im-me">';
            $td = '<td class="lm"></td>';
        } else {
            $write .= '<div class="im-item im-others">';
            $td = '<td class="lm"><span></span></td>';
        }
        $write .= '
        	<div class="im-message clearfix">
Example #3
0
function goodsShowAI($user, $table = 'lgsc_scanlog')
{
    $addsql = "{$table}.goodsid = lgsc_goods.id and {$table}.userid = '{$user['userid']}' group by typeid";
    $rows = MysqlRowSelect("{$table},lgsc_goods", 'lgsc_goods.typeid', $addsql);
    if ($rows != '-1') {
        $addsql = "typeid in (";
        foreach ($rows as $key => $value) {
            $addsql .= $value['typeid'] . ",";
        }
        $addsql = substr($addsql, 0, -1) . ') order by rand()';
        $row = MysqlRowSelect('lgsc_goods', 'id', $addsql, 5);
        if ($row == '-1') {
            return false;
        }
        $addsql = "lgsc_goods.id in(";
        foreach ($row as $key => $value) {
            $addsql .= $value['id'] . ",";
        }
        $addsql = substr($addsql, 0, -1) . ') ';
        return $addsql;
    } else {
        $row = MysqlRowSelect('lgsc_goods', 'id', "id != 0 order by rand()", 5);
        if ($row == '-1') {
            return false;
        }
        $addsql = "lgsc_goods.id in(";
        foreach ($row as $key => $value) {
            $addsql .= $value['id'] . ",";
        }
        $addsql = substr($addsql, 0, -1) . ') ';
        return $addsql;
    }
}
Example #4
0
             <div class="mt20">
        	<!--收藏店铺列表-->
			<div class="collgoods bgf5">
             	<div class="collgtitle">
                <div class="fl">
             		<!--<span class="all_xz"><a><label><input type="checkbox">全选</label></a></span>-->
                    <!--<span class="qx_xz"><a class="blue_link">取消选择</a></span>-->
                </div>
                <div class="fr cpage">
                <!--<span class="red-color"><i>1</i>/1</span><a class="c_left"></a><a class="c_nextpage">下一页</a>-->
                <div class="divclear"></div>
                </div>
                <div class="divclear"></div>
                 </div>
                  <?php 
$rows = MysqlRowSelect('lgsc_shopcollection,lgsc_shops', '*', $addsql, $limit);
if ($rows != '-1') {
    for ($i = 0, $n = count($rows); $i < $n; $i++) {
        $shopinfo = MysqlOneSelect('lgsc_shops', '*', "id=" . $rows[$i]['shopid']);
        ?>
                  <div class="shoplist">
                 	<div class="shopinfo fl">
                    	<div class="shoplogo"><div></div><a><img src="/<?php 
        echo $shopinfo['shop_logo'];
        ?>
" width="95" height="40"></a><!--<span>品牌直销</span>--></div>
                        <div class="shopname"><?php 
        echo $shopinfo['shopname'];
        ?>
</div>
                        <div class="gztime">关注时间:<span><?php 
Example #5
0
function listPlace($cid, $curid, $table, $field, $getUrl)
{
    $url = GetUrl($getUrl);
    $goods = MysqlRowSelect('lgsc_goods', $field, "typetid = '{$cid}'  group by {$field}");
    if ($goods == -1) {
        return '';
    }
    $write = '';
    for ($i = 0, $n = count($goods); $i < $n; $i++) {
        $classHot = '';
        $goodsaddress = MysqlOneSelect($table, "classname,id", "id=" . $goods[$i][$field]);
        if ($curid == $goods[$i][$field]) {
            $classHot = 'class="cur"';
        }
        $write .= "<a href='{$url}&{$getUrl}={$goodsaddress['id']}' {$classHot} >{$goodsaddress['classname']}</a>";
    }
    return $write;
}
Example #6
0
    }
    ?>
	
                            </div>
                        </div>
                    </li>
                    <?php 
    $i++;
}
?>
                </ul>
            </div>
        	<ul class="navmenu">
            	<li><a href="/">首页</a></li>
            	<?php 
$nav = MysqlRowSelect('lgsc_goodstype', '*', "parentid = 0 and checkinfo = 'true' order by orderid asc", '4');
for ($i = 0, $n = count($nav); $i < $n; $i++) {
    $url = "/goods.php?oncid=" . $nav[$i]['id'];
    ?>
                <li><a href="<?php 
    echo $url;
    ?>
" ><?php 
    echo $nav[$i]['classname'];
    ?>
</a></li>
                <?php 
}
?>
            	<li><a>饮食健康</a></li>
            	<li><a>菜谱大全</a></li>
Example #7
0
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php 
echo $cfg_webname;
?>
</title>
<link href="/css/css.css" rel="stylesheet" type="text/css" />
<link href="/css/common.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/templates/default/js/jquery.min.js"></script>
<script type="text/javascript" src="/templates/default/js/member.js"></script>
</head>


<?php 
$shop = MysqlRowSelect('lgsc_shops', 'id', "shop_prov='{$city}'", '9999');
$shopid = '';
$where = '';
if ($shop != '-1') {
    for ($i = 0, $n = count($shop); $i < $n; $i++) {
        $shopid .= $shop[$i]['id'] . ",";
    }
    $shopid = substr($shopid, 0, -1);
    $where = "and shopid in ( {$shopid} )";
}
?>
	
<body>
<!--顶部公共-->
<?php 
require_once dirname(__FILE__) . '/public/header.php';