goodsinfo.phtml
6.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
<?php
if(!empty($goodsInfo['image_list'])){
$goodsImage = $goodsInfo['image_list'][0];
?>
<script src="http://static.yohomarket.com/js/jquery-1.11.0.js" charset="UTF-8" type="text/javascript"></script>
<div style="display: none;">
<img src="<?php echo YHMUpload_Images::view($goodsImage['image_url'],600,600,1,'yhfair-product'); ?>">
<span><?php echo $goodsInfo['goods_name']; ?></span>
</div>
<?php } ?>
<div class="container">
<div class="hd ue-clear">
<div class="title">
<h1>友和市集</h1>
<p>汇集潮品 自由交易</p>
</div>
</div>
<div class="bd">
<div class="swipe" id="slider">
<ul class="swipe-wrap">
<?php foreach ($goodsInfo['image_list'] as $key => $val) { ?>
<li style="width:320px;height:320px;background:url(<?php echo YHMUpload_Images::view($val['image_url'],600,600,1,'yhfair-product'); ?>) no-repeat center;background-size:cover"><a href="javascript:;"></a></li>
<?php } ?>
</ul>
<div id="control-point" class="control-point ue-clear">
</div>
</div>
<div class="goods-info">
<h4><?php echo htmlspecialchars($goodsInfo['goods_name']); ?></h4>
<div class="ue-clear">
<strong class="price">¥<?php echo (int)$goodsInfo['sale_price']; ?></strong>
<span>品牌 :<em class="brand"><?php echo $goodsInfo['brand_name']; ?></em></span>
<span>品类 :<em class="goods-type"><?php echo $goodsInfo['category_name']; ?><?=$goodsInfo['gender']?></em></span>
</div>
<p><?php // echo Q_Utils_String::pregReplaceHtml($goodsInfo['describe']);?></p>
<p><?php echo htmlspecialchars($goodsInfo['describe']);?></p>
<a href="javascript:;" class="more">查看更多</a>
</div>
<div class="buyer-evaluation">
<?php if (!empty($comment_list)) { ?>
<div class="line"></div>
<h5>用户评价(<span class="evaluation-num"><?php echo $total_num; ?></span>)
<a class="more-icon" href="/m/share/comment?product_skc=<?php echo $product_skc;?>"></a>
</h5>
<?php foreach ($comment_list as $k => $v) { ?>
<div class="evaluation-box ue-clear">
<div class="buyer-pic"><a href="/m/share/store?store_id=<?php echo $v['comment_user_info']['store_id'];?>"><img src="<?php echo $v['comment_user_info']['head_ico']?>" width="24" height="24"/></a></div>
<div class="buyer-info" star="<?php echo $v['comment_user_info']['star']?>">
<a href="/m/share/store?store_id=<?php echo $v['comment_user_info']['store_id'];?>"><p class="buyer-name" style="width:260px;overflow:hidden; height: 20px"><?php echo $v['comment_user_info']['nick_name']?></p></a>
<p class="ue-clear">
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
</p>
</div>
<div class="goods-info">
<p><?php echo htmlspecialchars($v['content'])?></p>
</div>
</div>
<?php } } ?>
</div>
<div class="line"></div>
<div class="seller-info">
<div class="seller-box ue-clear" onclick="javascript:jumpStore();">
<div class="buyer-pic"><a href="/m/share/store?store_id=<?php echo $seller_info['store_id'];?>"><img src="<?php echo $seller_info['head_ico']?>" width="30" height="30"/></a></div>
<div class="buyer-info" star="<?php echo $seller_info['star']; ?>">
<p class="buyer-name ue-clear">
<span><?php echo mb_substr( $seller_info['nick_name'], 0, 10, 'UTF-8'); if (mb_strlen( $seller_info['nick_name'], 'UTF-8') >10){echo "...";} ?></span>
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
<i class="star"></i>
</p>
<p class="ue-clear">
<span><?php echo $seller_info['identity']; ?></span>
</p>
</div>
<a href="javascript:;" class="more-icon"></a>
</div>
<div class="seller-goods ue-clear">
<span class="in-sale">在售商品:<em><?php echo $store_info['sell_num']; ?></em></span>
<span class="sold">已售商品:<em><?php echo $store_info['sold_num']; ?></em></span>
<span class="purchase">已购商品:<em><?php echo $store_info['purchased_num']; ?></em></span>
</div>
</div>
<div class="line"></div>
<div class="goods-btns ue-clear">
<?php if (strpos($_SERVER["HTTP_USER_AGENT"],'iPhone') == false) { ?>
<a href="/m/share/store?store_id=<?php echo $store_info['store_id'];?>" class="collect-btn-elkan">浏览店铺</a>
<a href="http://android.app.qq.com/myapp/detail.htm?apkName=cn.yoho.marketplace" class="buy-btn-elkan">立即购买</a>
<!--<a href="/app/openGoods?product_skc=<?php echo $goodsInfo['product_skc'];?>" class="buy-btn-elkan">立即购买</a>-->
<?php } else { ?>
<a href="/m/share/store?store_id=<?php echo $store_info['store_id'];?>" class="collect-btn-elkan">浏览店铺</a>
<!---<a href="http://mp.weixin.qq.com/mp/redirect?url=http%3A%2F%2Fwww.yohomarket.cn%2Fapp%2Fopengoods%2Fproduct_skc%2F<?php echo $goodsInfo['product_skc'];?>" class="collect-btn-elkan">下载App立即体验</a> 后面%23rd 是#23rd-->
<a href="http://mp.weixin.qq.com/mp/redirect?url=http%3A%2F%2Fitunes.apple.com%2Fcn%2Fapp%2Fid913948820%23rd" class="buy-btn-elkan">立即购买</a>
<?php } ?>
</div>
</div>
</div>
<script type="text/javascript">
$(function(){
var textLen = $('.goods-info').find("p").text().length,
attrLen = $('.goods-info').find("p").attr("title").length;
if(textLen < attrLen){
$('.more').css('display','block');
}
})
function jumpStore(){
location.href='/m/share/store?store_id=<?php echo $seller_info['store_id'];?>';
}
</script>