index.html 11.3 KB
<!DOCTYPE html>
<!-- saved from url=(0061)http://localhost:6001/activity/marketExtend?activityCode=1001 -->
<html style="font-size: 23.4375px;"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        
        <title></title>
        <meta name="keywords" content="">
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
        <meta http-equiv="cleartype" content="on">
        <meta name="apple-mobile-web-app-status-bar-style" content="black">
        <meta content="telephone=no" name="format-detection">
        <meta content="email=no" name="format-detection">
        <link rel="dns-prefetch" href="http://cdn.yoho.cn/">
        <link rel="dns-prefetch" href="http://static.yohobuy.com/">
        <link rel="dns-prefetch" href="http://img12.static.yhbimg.com/">
        <link rel="dns-prefetch" href="http://img13.static.yhbimg.com/">
        <script type="text/javascript">
            (function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=640){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/640)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
        </script>
        <script type="text/javascript" src="/union/js/jquery-1.12.0.min.js"></script>
        <script type="text/javascript" src="/union/js/jquery.json.js"></script>
        <script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script>
        
            <link rel="stylesheet" href="./css/index.css">
        <link rel="apple-touch-icon-precomposed" href="http://static.yohobuy.com/m/v1/img/touch/apple-touch-icon-144x144-precomposed-new.png">
        <link rel="apple-touch-startup-image" sizes="640x920" href="http://static.yohobuy.com/m/v1/img/startup/startup-retina.png" media="screen and (max-device-width: 480px) and (-webkit-min-device-pixel-ratio: 2)">
        <link rel="apple-touch-startup-image" sizes="320x460" href="http://static.yohobuy.com/m/v1/img/startup/startup.png" media="screen and (max-device-width: 320)">
</head>
    <body>
    	<script>
    	var activityInfo = {};

        (function(w, d, s, j, f) {
            var a = d.createElement(s);
            var m = d.getElementsByTagName(s)[0];

            w.YohoAcquisitionObject = f;

            w[f] = function() {
                w[f].p = arguments;
            };

            a.async = 1;
            a.src = j;
            m.parentNode.insertBefore(a, m);
        }(window, document, 'script', (document.location.protocol === 'https:' ? 'https:' : 'http:') + '//cdn.yoho.cn/yas-jssdk/2.3.5/yas.js', '_yas'));

        (function() {
            if (window._yas) {
                window._yas(1 * new Date(), '2.3.5', 'yohobuy_m', '', '', '');
            }
        }());


        /**
    	 * html中传递参数,获取方法
    	 * @param key
    	 * @returns
    	 */
    	function getQueryStr(key){
    	    var svalue = window.location.search.match(new RegExp("[\?\&]" + key + "=([^\&]*)(\&?)","i"));
    	    var str = svalue ? svalue[1] : svalue;
    	    return str == null ? "" : str;
    	}
		 var activityCode = getQueryStr("code");
        if (activityCode == ""){
            activityCode = getQueryStr("union_type");
        }
		 var activityData = null;

        let search = window.location.search;
        if (search.indexOf('&expires=') === -1) {
            search = search ? (search + '&') : '?';
            search = search + 'expires=' + (7 * 24 * 60 * 60 * 1000);
            search = search + '&union_type='+activityCode;
        }
        $('<iframe style="display:none;" src="//m.yohobuy.com/activity/wechat/1111' + search + '"></iframe>').prependTo('body');


        </script>
        <div class="main-wrap">

            <div class="receive-coupon-page">
    <div class="bg-contain">
        <img class="img1">
        <img class="img2">
    </div>
    <p class="hidden" id="activityEnded"></p>
    <p class="hidden" id="newUser"></p>
    <p class="hidden" id="tipMessage"></p>
    <p class="hidden" id="activityID"></p>
    <input type="hidden" id="shareTitle" value="Hi,有货狂撒红包啦,快来抢!">
    <input type="hidden" id="shareDesc" value="YohoBuy!有货千元新客红包,先来先抢!">
    <input type="hidden" id="shareImg" value="http://img10.static.yhbimg.com/yhb-img01/2016/06/17/16/01f5381680604552fd00d21a32f9c3a1cf.png">
    <input type="hidden" id="shareLink" value="&amp;{tencentmkt.shareUrl}?activityCode=1001">
    <input type="hidden" id="activityCode" value="1001">

    <div class="page">
        <div class="gain-coupon-centent hidden">
            <div class="coupon">
                <img src="http://img11.static.yhbimg.com/yhb-img01/2016/06/17/16/01aaaef9795906d0de878bc853ce9adde2.png">
            </div>
            <p>登录Yoho!Buy有货可领取全部优惠券</p>

            <div class="use-coupon-btn">
                <a class="use-coupon" href="http://a.app.qq.com/o/simple.jsp?pkgname=com.yoho">马上去Yoho!Buy有货使用</a>
            </div>
            <span class="wepVersion-btn footer-btn">
                <a class="go-wep" href="http://union.yohobuy.com/go?client_id=3387&amp;channel_code=txsplq&amp;append=&amp;go_url=http://m.yohobuy.com/?utm_source=txsplq&amp;utm_medium=cpc&amp;utm_campaign=txsplq">网页版</a>
            </span>
            <span class="gain-description-btn footer-btn">活动说明</span>
        </div>

        <div class="coupon-centent">
            <div class="title">
            </div>
            
            <div class="under-title">
                <div class="input-content phone-input-content">
                    <input id="phone" type="text" placeholder="请输入手机号" maxlength="11">
                    <i class="clear-input iconfont hidden clear-mobile"></i>

                    <div id="getCoupon">领取红包</div>
                </div>

                <div class="input-content vertify-input-content hidden">
                    <input id="verification" type="text" placeholder="请输入验证码" maxlength="4">
                    <i class="clear-input iconfont hidden clear-verify"></i>
                    <div id="regist">注册领红包</div>
                </div>

                <div class="coupon-description">
                    <img class="img3">
                </div>

                <div class="description-btn footer-btn">活动说明</div>
            </div>

            
        </div>
    </div>
    
    <div class="tip-wrap hidden">
        <div class="tip fail">
            <div class="header">
            </div>

            <div class="title">
                
                <!-- 优惠券已领光 -->
            </div>

            <div class="logo">
            </div>
        </div>
    </div>
    
    <div class="messages hidden" id="dialog">
        <div class="content">
            <p class="phone-error"></p><p>
        </p></div>
    </div>

    <div class="mask hidden"></div>
    <div class="dialog hidden" id="message">
        <span class="close"></span>
        <span id="activityDesc">
            <div class="activity-message">
                <h3>活动说明</h3>
                <div class="message">
                </div>
            </div>
        </span>
    </div>

                <div class="mask hidden"></div>
                <div class="dialog hidden" id="oldUserDiv">
                    <span class="close"></span>
        <span id="oldUserSpan">
            <div class="activity-message2">
                <div class="mess_outer">
                    <div class="mess_wrap">
                        <div class="message">
                            <p>我是文字我是文字我是文字我是文字我是文字我是文字我是文字我是文字我是文字我是文</p>
                        </div>
                    </div>
                </div>
                <h3 class="oldUserButton"><a href="http://www.yohobuy.com">按钮名称</a></h3>
            </div>
        </span>
                </div>


</div>

        </div>

           <script type="text/javascript" src="/union/tencentMkt/js/coupon.js"></script>
<script>
/**
 * 微信分享 
 */
(function($) {
    if (typeof(wx) == "undefined") {
        return;
    }
    
    $.post("/union/tencentMkt/TencentMktController/getActivityInfo", {
    	activityCode: activityCode
    }, function(data) {
    	if (!data || data.code != 200 || !data.data) {
    		return;
    	}
    	data = data.data;
    	var _weChatInterface = 'http://www.yohoshow.com/api/wechat/getSignPackage';
        var shareTitle = data.shareTitle;
        var shareImg = data.shareImgUrl;
        var shareDesc = data.shareContent;
        var shareLink = data.shareUrl;
     
        $.getJSON(_weChatInterface + '?pageurl=' +
                encodeURIComponent(location.href.split('#')[0]) + '&callback=?', function(json) {
            var _appId, _timestamp, _nonceStr, _signature;
            if (json !== undefined && json !== '') {
                _appId = json.appId.toString();
                _timestamp = json.timestamp;
                _nonceStr = json.nonceStr.toString();
                _signature = json.signature.toString();

                wx.config({
                    debug: false,
                    appId: _appId,
                    timestamp: _timestamp,
                    nonceStr: _nonceStr,
                    signature: _signature,
                    jsApiList: [
                        'checkJsApi',
                        'onMenuShareTimeline',
                        'onMenuShareAppMessage',
                        'onMenuShareQQ',
                        'onMenuShareWeibo',
                        'hideMenuItems',
                        'showMenuItems',
                        'hideAllNonBaseMenuItem',
                        'showAllNonBaseMenuItem',
                        'translateVoice',
                        'startRecord',
                        'stopRecord',
                        'onRecordEnd',
                        'playVoice',
                        'pauseVoice',
                        'stopVoice',
                        'uploadVoice',
                        'downloadVoice',
                        'chooseImage',
                        'previewImage',
                        'uploadImage',
                        'downloadImage',
                        'getNetworkType',
                        'openLocation',
                        'getLocation',
                        'hideOptionMenu',
                        'showOptionMenu',
                        'closeWindow',
                        'scanQRCode',
                        'chooseWXPay',
                        'openProductSpecificView',
                        'addCard',
                        'chooseCard',
                        'openCard'
                    ]
                });
            }
        });
        wx.ready(function() {
        
            var shareData = {
                title: shareTitle,
                desc: shareDesc,
                imgUrl: shareImg,
                link: shareLink
            };
            wx.onMenuShareAppMessage(shareData);
            wx.onMenuShareTimeline(shareData);
            wx.onMenuShareQQ(shareData);
            wx.onMenuShareWeibo(shareData);
        });
    }, "json");
    
}(jQuery));
</script>

</body></html>