function get_the_share_detail_template() { global $xt_user_avatar; $cacheObj = get_the_share_cachedata(); $_item = $cacheObj['item']; $_title = get_the_share_title(); $_fxText = '元'; $isJifenbao = xt_fanxian_is_jifenbao(get_the_share_fromtype()); if ($isJifenbao) { $_fxText = xt_jifenbao_text(); } ?> <script type="text/javascript"> if(typeof(XT)!='undefined'){XT.share_id=<?php the_share_id(); ?> ;} </script> <div class="row-fluid" style="background-color:white;"> <div class="span12 media well well-small" style="margin-left:0px;margin-bottom:0px;"> <a style="display:block;width:40px;" class="pull-left X_Nick" data-value="<?php echo get_the_share_userid(); ?> " href="<?php xt_the_user_url(get_the_share_userid()); ?> " target="_blank" rel="nofollow"><img src="<?php xt_the_user_pic($xt_user_avatar); ?> " style="width:40px;height:40px;"></a> <div class="media-body"> <h5 class="media-heading"><a class="xt-red X_Nick" data-value="<?php echo get_the_share_userid(); ?> " href="<?php xt_the_user_url(get_the_share_userid()); ?> " target="_blank"><?php the_share_username(); ?> </a> 分享了该宝贝<span class="pull-right"><?php the_share_time_human(); ?> </span></h5> <div class="media" style="margin-top:0px;"><?php the_share_content(); ?> </div> </div> </div> <div class="span12 media" style="margin-left:0px;padding:5px;"> <div class="pull-left"> <a rel="nofollow" href="<?php the_share_go(); ?> " target="_blank"> <img src="<?php the_share_picurl(450); ?> " alt="<?php echo $_title; ?> "/> <?php echo get_the_admin_tool_share(get_the_share_id()); ?> </a> </div> <div class="pull-left" style="width:250px"> <h1 style="font-size:16px;line-height:22px;margin-top: 0px;"><?php echo '<img src="' . get_the_share_ico() . '"/>'; ?> <a rel="nofollow" title="<?php echo $_title; ?> " target="_blank" href="<?php the_share_go(); ?> "><?php echo $_title; ?> </a></h1> <a id="X_Share-Detail-Buy" data-from="<?php echo get_the_share_fromtype(); ?> " data-type="<?php echo $isJifenbao ? 'jifenbao' : 'cash'; ?> " data-id="<?php echo get_the_share_key(); ?> " href="<?php the_share_go(); ?> " target="_blank" rel="nofollow" class="btn btn-primary" style="padding:4px 20px;font-size:16px;font-weight:bold;">¥<?php the_share_price(); ?> 去购买</a> <?php if (xt_fanxian_is_sharebuy()) { ?> <div class="clearfix"><?php echo xt_fanxian_html('{fx}', $_fxText, 'margin-top:10px;'); ?> </div> <?php } ?> <div class="clearfix" style="margin-top:10px;padding-bottom: 10px;border-bottom: 1px solid #EAEAEA;"> <a class="badge badge-fav" title="喜欢" data-id="<?php the_share_id(); ?> " data-type="1" data-uid="<?php the_share_userid(); ?> "><?php the_share_favcount(); ?> <i class="icon-heart icon-white"></i></a> <!--<a href="javascript:;" class="xt-album-add" data-id="<?php //the_share_id() ?> " data-pic="<?php //the_share_picurl(160) ?> ">加入专辑</a>--> </div> <div class="well well-small clearfix" style="margin-top:15px;"> <?php $_tags = explode(" ", get_the_share_tags()); foreach ($_tags as $_tag) { echo "<a href=\"" . xt_get_shares_search_url(array('s' => $_tag)) . "\" target=\"_blank\" style=\"float: left;margin-left: 8px;\">{$_tag}</a>"; } ?> </div> <?php $bdshare = xt_bdshare(); if ($bdshare > 0) { ?> <!-- Baidu Button BEGIN --> <div id="bdshare" class="bdshare_b" style="line-height: 12px;"><img src="http://share.baidu.com/static/images/type-button-1.jpg" /> <a class="shareCount"></a> </div> <script type="text/javascript"> document.getElementById("bdshell_js").src = "http://share.baidu.com/static/js/shell_v2.js?cdnversion=" + new Date().getHours(); </script> <!-- Baidu Button END --> <?php } ?> </div> </div> </div> <?php }
function xt_widget_template_grid_sidesmall_item_temai($_count, $rate, $item, $isJifenbao, $fanxianText) { $_title = esc_html(str_replace(array('<span class = H>', '</span>'), array('', ''), $item->title)); $_pic = str_replace('_b.jpg', '', $item->pic_url) . '_100x100.jpg'; $fx = round($rate / 100 * ($item->commission_rate / 100 * $item->promotion_price), 2); $_url = xt_jump_url(array('type' => 'temai', 'id' => $item->track_iid, 'title' => $_title, 'url' => $item->detail_url, 'fx' => $fx)); ?> <li class="media"<?php echo $_count == 0 ? ' style="padding-top:0px;"' : ''; ?> > <a rel="nofollow" class="pull-left" href="<?php echo $_url; ?> " target="_blank"> <?php xt_write_pic(base64_encode($_pic), $_title, 0, 0, 'media-object'); ?> <span><i>销量:<?php echo $item->volume; ?> </i></span> </a> <div class="media-body"> <h4 class="media-heading"><a rel="nofollow" class="text-gray" href="<?php echo $_url; ?> " target="_blank"><?php echo $_title; ?> </a></h4> <div class="media"> <p><span>¥</span><strong><?php echo $item->promotion_price; ?> </strong></p> <?php echo xt_fanxian_html($isJifenbao ? $fx * 100 : $fx, $fanxianText); ?> </div> </div> </li> <?php }