<%@ page language="C#" autoeventwireup="true" inherits="zyqbm, App_Web_l2p10xlz" %>

<!DOCTYPE html>
<html lang="en">
<head >
 
<title>邀请码-<%Response.Write(titlestr);%></title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
     <meta http-equiv="Content-Language" content="zh-CN" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width,
                initial-scale=1.0,
                minimum-scale=1.0,
                maximum-scale=1.0,
                user-scalable=no" />
    <script src="/content/js/jquery-2.1.5.min.js" type="text/javascript"></script>
    <script src="/content/layer/layer.js" type="text/javascript"></script>
    <script type="text/javascript">
        layer.config({
            extend: "extend/layer.ext.js"
        });
    </script>

    <!-- Bootstrap -->
    <link href="/content/css/bootstrap.css" rel="stylesheet" />
   <!-- Font Awesome -->
  <%--  <link href="/content/css/font-awesome/css/font-awesome.min.css" rel="stylesheet" />--%>
    <!-- Custom Theme Style -->
    <link href="/content/css/custom.min.css" rel="stylesheet" />
    <link href="/content/css/contextMenu.css" rel="stylesheet" />
      <link rel="stylesheet" href="/content/font/iconfont.css" />
     <link rel="stylesheet" href="/content/css/main.css"/>
    <script src="/content/js/contextMenu.js" type="text/javascript"></script>
    <script src="/content/js/xggbf.js" type="text/javascript"></script>
    <script src="/content/js/zmmxg.js" type="text/javascript"></script>
  
</head>
    
    <body>
          
         <div id="JS_div" runat="server">    </div>
   <!-- 左侧菜单内容 -->
         <%Response.Write(tempnavmenu); %>

 <!-- 左侧菜单内容结束 -->
   

     <!-- 右页面内容 -->
          <div class="bg-danger pagebody">
<div class="right_col" role="main"   id="right1"  >
<script type="text/javascript">
    var var2 = window.innerHeight - 58;
    right1.style.setProperty('min-height', var2 + 'px', 'important');
</script>
        <div class="page-title">
            <div class="title_left">
                <h3>邀请码</h3>
                <h4> &nbsp;&nbsp;&nbsp;&nbsp;</h4>
            </div>
        </div>
        <div class="clearfix"></div>
    <!--替换内容-->
        <div class="row">
            <div class="clearfix"></div>
            <div class="col-md-12 col-sm-12 col-xs-12">
                  <div class="x_content">
                         <%if (QHDEDUPAGE.IsWap() == true)
              { %>
                        <input type="button" onclick="javascript: window.location.reload();" class="btn btn-primary" value="重新生成" />
                       <%} %>
                              <form class="form-horizontal form-label-left" novalidate="">
                                  <div id="Div1" runat="server">     </div>
                                <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">
                                        邀请码：
                                    </label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                         <textarea name="fvyqbm"  id="fvyqbm"   rows="4" cols="80"><%Response.Write(fvyqbm); %></textarea>
                                     </div>
                                    
                                </div>
                                    <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">
                                        地址：
                                    </label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                     <textarea name="fvaddr"  id="fvaddr"   rows="6" cols="80"><%Response.Write(fvaddr); %></textarea>
                                   </div>
                                    
                                      

                                </div>

                                   <div class="item form-group bad">
                                     <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">
                                        
                                    </label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                        <img id="picEncode"/>
                                   </div>
                                    
                                        

                                </div>

                                <div class="ln_solid"></div>
                                <div class="form-group">
                                    <div class="col-md-6 col-md-offset-3">
                                           <%if (QHDEDUPAGE.IsWap() != true)
              { %>
                                        <input type="button" onclick="javascript: window.location.reload();" class="btn btn-primary" value="重新生成" />
                                         <%} %>
                                         <input type="button" onclick="javascript: copyyqm1();" class="btn btn-primary" value="复制邀请码" />
                                         <input type="button" onclick="javascript: copyyqm2();" class="btn btn-primary" value="复制地址" />
                                        <input type="button"  class="btn btn-primary"  onclick="createQR_Click()" title="生成二维码" value="二维码"/>
            
                                    </div>
                                </div>
                            </form>
                   </div>
            </div>
        </div>
    <!--替换内容结束-->
  </div>
</div>
 <!-- 右页面内容完成 -->
    <!-- 版权内容 -->    
      <% Response.Write(copystr);%>
         <!-- 版权内容完成 -->
   <script src="/content/js/zmain.js" charset="utf-8" type="text/javascript"></script>
          <script  charset="utf-8" type="text/javascript">
              function copyyqm1()
              {
                  var temp = $("#fvyqbm").val();
                  //window.clipboardData.setData("text",temp);
                  // $("input[name='fitsxh']").get(index).select();
                  $("#fvyqbm").select();
                  window.clipboardData.setData('Text', temp);
                 // alert(window.clipboardData.getData('Text'));
                  //alert(temp);
              }

              function copyyqm2() {
                  var temp = $("#fvaddr").val();
                  $("#fvaddr").select();
                  window.clipboardData.setData('Text', temp);
              }

              function createQR_Click() {
                  var EncodeData = $("#fvaddr").val();   //二维码地址
                  if (EncodeData == null || EncodeData == "") {
                      alert("请输入要转换的地址");
                      return;
                  }
                  else {
                      //$.get("/AjaxHandle/QR/QrImgBulid.ashx", { "EncodeData": EncodeData }, function (result) {
                      var url = "/qr/QrImgBulid.ashx?EncodeData=" + EncodeData;
                      $("#picEncode").attr("src", url);   //动态为img赋值，生成的图片为二进制，因此其连接为aspx,或者ashx.
                      //})
                  }
              }

$(document).ready(function (){
createQR_Click();
});

          </script>
</body>
</html>