123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187 |
- <section class="toast" style="display:none;">错误信息</section>
- <{if !$cutScreenInfo && $display == 1}>
- <footer>
- <ul>
- <li <{if $action != 'gift'}>class="active"<{/if}>><a href="<{$listUrl}>"><i class="icon"><img src="<{$platform.home_img_url}>"></i><span><{$platform.home_img_text}></span></a></li>
- <li <{if $action == 'gift'}>class="active"<{/if}>><a href="<{$giftsUrl}>"><i class="icon"><img src="<{$platform.gift_img_url}>"></i><span><{$platform.gift_img_text}></span></a></li>
- <{if $platform.zs_img_link}>
- <li><a href="<{$platform.zs_img_link}>"><i class="icon"><img src="<{$platform.zs_img_url}>"></i><span><{$platform.zs_img_text}></span></a></li>
- <{/if}>
- <li class="bottom_follow"><a href="<{$platform.follow_url}>" target="_blank"><i class="icon"><img src="<{$platform.follow_img_url}>"></i><span><{$platform.follow_img_text}></span></a></li>
- <li style="display:none"><a class="bottom_share" href="<{$platform.share_url}>" ><i class="icon"><img src="<{$platform.share_img_url}>"></i><span><{$platform.share_img_text}></span></a></li>
- </ul>
- </footer>
- <{/if}>
- <script type="text/javascript">
-
- function loadLogin()
- {
- <{if $applogin && $applogin == 1}>
- istoken('<{$info.thisUrl}>');
- <{else}>
- $('#loginbox').show();
- <{/if}>
- /*
- app = checkApp();
- if (app) {
- istoken('<{$info.thisUrl}>');
- } else {
- $('#loginbox').show();
- }
- */
- }
- function toast(content, url)
- {
- var e = $(".toast");
- e.html(content).show();
- var func = function(url)
- {
- e.hide();
- if (url == 1) {
- return;
- } else if (url) {
- location.href = url;
- } else {
- location.reload();
- }
- };
- setTimeout(function(){func(url)}, 1000);
- }
- function checkApp() {
- var u = navigator.userAgent.toLowerCase();
- var isApple = /iphone|ipad|ipod|ios|android/i.test(u);
- var isAndroid = /android/i.test(u);
- var isWeixin = /micromessenger/i.test(u);
- if (!isWeixin) {
- return true;
- } else {
- return false;
- }
- }
- function share_button(e, title, url, img, content) {
- console.log(title);
- if (checkApp()) {
- //e.parent().show();
- e.show();
- e.click(function()
- {
- WX_share(url, content, title, img);
- })
- } else {
- //e.parent().hide();
- e.hide();
- }
- }
- function buy_button()
- {
- if ($('.buy_button').length) {
- var buy = $('.buy_button');
- if (checkApp()) {
- buy.attr('href', 'javascript:;');
- var app = buy.attr('data-app');
- buy.click(function() {
- //app内链接
- })
- } else {
- buy.attr('href', buy.attr('data-weixin'));
- }
-
- }
- }
- function yaoqing()
- {
- if ($(".yaoqing").length) {
- var app = checkApp();
- if (app) {
- $(".yaoqing").addClass('share_button');
- } else {
- $(".yaoqing").removeClass('share_button');
- /*
- $(".yaoqing").click(function()
- {
- toast('点击右上角,分享邀请好友为你加油!', 1);
- });
- */
- }
- }
- }
- </script>
- <{if !$notShowWeixinShare && !$weixinShare.notAllow}>
- <script type="text/javascript">
- var URL = window.location.href, site;
- site = 1;
- console.log(share_url);
- new brickjs.MShare({
- website : 'sg',
- site: site,
- catalog: "",
- sUrl: share_url, //分享地址
- title: share_title,
- imgUrl: share_img,
- imgWidth: "640",
- imgHeight: "640",
- source_id : 1,
- source_table : 'onepage',
- desc: share_content,
- appKey: {
- tsina: "2412621184"
- },
- ralateUid: '1658402750',
- wxGuide: {
- imgUrl: share_img,
- width: 100,
- height: 100,
- style: {
- right: 0,
- top: 0
- }
- }
- });
- function init()
- {
- yaoqing();
- buy_button();
- if ($('.share_button').length) {
- share_button($('.share_button'), share_title, share_url, share_img, share_content);
- }
- if (checkApp()) {
- if ($('.bottom_share').length) {
- $('.bottom_follow').hide();
- share_button($('.bottom_share'), share_title, share_url, share_img, share_content);
- }
- }
- }
- $(function()
- {
- init();
- })
- </script>
- <{else}>
- <script>
- //关闭分享按钮
- wx.hideOptionMenu();
- </script>
- <{/if}>
- </body>
- </html>
|