|
|
@@ -0,0 +1,258 @@
|
|
|
+<!DOCTYPE html>
|
|
|
+<html xmlns="http://www.w3.org/1999/html">
|
|
|
+<head>
|
|
|
+ <meta charset="utf-8">
|
|
|
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
|
+ <title>安全猫官网</title>
|
|
|
+ <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
|
|
|
+ <!-- Bootstrap 3.3.7 -->
|
|
|
+ <link rel="stylesheet" href="{$Think.PLUGINS_SITE_ROOT}/layui/css/layui.css">
|
|
|
+ <link rel="stylesheet" href="{$Think.USER_SITE_ROOT}/css/admin.css">
|
|
|
+ <link rel="stylesheet" href="{$Think.USER_SITE_ROOT}/iconfont/iconfont.css">
|
|
|
+ <script src="{$Think.PLUGINS_SITE_ROOT}/jquery-2.1.4.min.js"></script>
|
|
|
+ <script src="{$Think.USER_SITE_ROOT}/js/admin.js"></script>
|
|
|
+ <script type="text/javascript" src="{$Think.PLUGINS_SITE_ROOT}/layui/layui.js"></script>
|
|
|
+ <script type="text/javascript">
|
|
|
+ var BASESITEROOT = "{$Think.BASE_SITE_ROOT}";
|
|
|
+ var ADMINSITEROOT = "{$Think.ADMIN_SITE_ROOT}";
|
|
|
+ var BASESITEURL = "{$Think.BASE_SITE_URL}";
|
|
|
+ var HOMESITEURL = "{$Think.HOME_SITE_URL}";
|
|
|
+ var ADMINSITEURL = "{$Think.ADMIN_SITE_URL}";
|
|
|
+ </script>
|
|
|
+</head>
|
|
|
+<style type="text/css">
|
|
|
+ .layui-tab {
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+ top: 0;
|
|
|
+ height: 100%;
|
|
|
+ width: 100%;
|
|
|
+ z-index: 10;
|
|
|
+ margin: 0;
|
|
|
+ border: none;
|
|
|
+ overflow: hidden;
|
|
|
+ }
|
|
|
+
|
|
|
+ .layui-tab-content {
|
|
|
+ padding: 0;
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+
|
|
|
+ .layui-tab-item {
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+ .treeview .admin-nav-item{
|
|
|
+ color: #a7b1c2 !important;
|
|
|
+ padding-left: 5px;
|
|
|
+ }
|
|
|
+ .treeview .admin-nav-item:hover{
|
|
|
+ color: #fff !important;
|
|
|
+ }
|
|
|
+</style>
|
|
|
+<div class="admincp-header">
|
|
|
+ <div class="logo">
|
|
|
+ <img width="200" src="{$Think.USER_SITE_ROOT}/images/backlogo.png"/>
|
|
|
+ </div>
|
|
|
+ <div class="navbar">
|
|
|
+ <ul class="fr" style="float:right" id="nav">
|
|
|
+ <li><a href="{:url('Login/index')}">{$Think.lang.login}</a></li>
|
|
|
+ <li><a href="{:url('Register/index')}">{$Think.lang.register}</a></li>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+</div>
|
|
|
+<div class="login">
|
|
|
+ <div class="login_body">
|
|
|
+ <div class="login_header">
|
|
|
+ <img style="margin: 0px auto; display: block; margin-bottom: 10px;" src="{$Think.ADMIN_SITE_ROOT}/images/logo.png"/>
|
|
|
+ </div>
|
|
|
+ <div class="login_content">
|
|
|
+ <form method="post">
|
|
|
+ <div class="form-group">
|
|
|
+ <input type="text" name="user_email" placeholder="{:lang('email_address')}" required class="text">
|
|
|
+ </div>
|
|
|
+ <div class="form-group">
|
|
|
+ <input type="text" name="user_password" id="user_password" placeholder="{:lang('install_pasword')}" required class="text">
|
|
|
+ <div id="pwd" style="font-size: 10px;color:#aaa;">密码必须包含有字母,数字,符号,密码长度为6-20个字符</div>
|
|
|
+ </div>
|
|
|
+ <div class="form-group">
|
|
|
+ <input type="text" id="confirm_password" name="confirm_password" placeholder="{:lang('confirm_password')}" required class="text">
|
|
|
+ <div id="confirm_pwd"></div>
|
|
|
+ </div>
|
|
|
+ <div class="form-group">
|
|
|
+ <input type="text" id="user_phone" name="user_phone" placeholder="{:lang('phone')}" required class="text">
|
|
|
+ <div id="phone"></div>
|
|
|
+ </div>
|
|
|
+ <div class="form-group">
|
|
|
+ <input type="text" name="captcha" placeholder="{:lang('login_captcha')}" required class="text" style="width:60%;float:left;">
|
|
|
+ <img src="{:captcha_src()}" style="width:30%;height:38px;" id="change_captcha"/>
|
|
|
+ </div>
|
|
|
+ <input type="checkbox" name="ch_box" id="ch_box" onclick="c_box()" /><span>我已阅读并同意
|
|
|
+ <a href="xieyi.html" target="_blank">《用户协议》</a>及<a href="xieyi.html" target="_blank">《法律声明及隐私条款》</a></span><br><br>
|
|
|
+ <div class="form-group" style="text-align: center;">
|
|
|
+ <input type="submit" class="layui-btn" id="layui-btn" value="{:lang('register_sumbit')}" lay-submit lay-filter="login"/>
|
|
|
+ </div>
|
|
|
+ </form>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</div>
|
|
|
+<script>
|
|
|
+ //密码 校验
|
|
|
+ $("#user_password").blur(function(){
|
|
|
+ var password = document.getElementById("user_password").value;
|
|
|
+ //console.log(password);
|
|
|
+ var patrn=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{6,20}$/;
|
|
|
+ if (!patrn.exec(password)){
|
|
|
+ //console.log(1);
|
|
|
+// var addhtml = document.getElementById("pwd");
|
|
|
+// if(document.getElementById("tishi") == null){
|
|
|
+// addhtml.innerHTML = addhtml.innerText+'<span id="tishi" style="color:red;font-size: 12px;"><br>密码不合法</span>';
|
|
|
+// }
|
|
|
+ document.getElementById("user_password").style.borderColor = "red";
|
|
|
+ }else{
|
|
|
+ //console.log(2);
|
|
|
+// var remove = document.getElementById("tishi");
|
|
|
+// remove.parentNode.removeChild(remove);
|
|
|
+ document.getElementById("user_password").style.borderColor = "#e6e6e6";
|
|
|
+ }
|
|
|
+ });
|
|
|
+ $("#confirm_password").blur(function(){
|
|
|
+ var password = document.getElementById("confirm_password").value;
|
|
|
+ //console.log(password);
|
|
|
+ var patrn=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{6,20}$/;
|
|
|
+ if (!patrn.exec(password)){
|
|
|
+ //console.log(1);
|
|
|
+// var addhtml = document.getElementById("confirm_pwd");
|
|
|
+// if(document.getElementById("tishi_pwd") == null){
|
|
|
+// addhtml.innerHTML = addhtml.innerText+'<span id="tishi_pwd" style="color:red;font-size: 12px;"><br>密码不合法</span>';
|
|
|
+// }
|
|
|
+ document.getElementById("confirm_password").style.borderColor = "red";
|
|
|
+ }else{
|
|
|
+ //console.log(2);
|
|
|
+// var remove = document.getElementById("tishi_pwd");
|
|
|
+// remove.parentNode.removeChild(remove);
|
|
|
+ document.getElementById("confirm_password").style.borderColor = "#e6e6e6";
|
|
|
+ }
|
|
|
+ });
|
|
|
+ //电话校验
|
|
|
+ $("#user_phone").blur(function(){
|
|
|
+ var password = document.getElementById("user_phone").value;
|
|
|
+ //console.log(password);
|
|
|
+ var patrn=/^1[3456789]\d{9}$/;
|
|
|
+ if (!patrn.exec(password)){
|
|
|
+ //console.log(1);
|
|
|
+// var addhtml = document.getElementById("phone");
|
|
|
+// if(document.getElementById("tishi_phone") == null){
|
|
|
+// addhtml.innerHTML = addhtml.innerText+'<span id="tishi_phone" style="color:red;font-size: 12px;"><br>电话号码不合法</span>';
|
|
|
+// }
|
|
|
+ document.getElementById("user_phone").style.borderColor = "red";
|
|
|
+ }else{
|
|
|
+ //console.log(2);
|
|
|
+// var remove = document.getElementById("tishi_phone");
|
|
|
+// remove.parentNode.removeChild(remove);
|
|
|
+ document.getElementById("user_phone").style.borderColor = "#e6e6e6";
|
|
|
+ }
|
|
|
+ });
|
|
|
+ // 协议 校验
|
|
|
+ function c_box(){
|
|
|
+ var c_b = document.getElementById("ch_box");
|
|
|
+ var c_sub = document.getElementById("layui-btn");
|
|
|
+ if(c_b.checked){
|
|
|
+ c_sub.disabled=false;
|
|
|
+ }else{
|
|
|
+ c_sub.disabled=true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ $('#change_captcha').click(function () {
|
|
|
+ $(this).attr('src', '{:captcha_src()}?'+(new Date().getTime()));
|
|
|
+ });
|
|
|
+</script>
|
|
|
+<script type="text/javascript">
|
|
|
+ var width =document.body.clientWidth;
|
|
|
+ var changesmall =function(){
|
|
|
+ if($(".admincp-container-left").css("width")=="200px"){
|
|
|
+ $(".admincp-container-left").css("width","55px");
|
|
|
+ $("#layout-center").css({"position":"absolute","left":"55px","width":(width-55)+"px"});
|
|
|
+ $(".title").attr('title',$(".title .title-txt").html())
|
|
|
+ $(".title .title-txt").css("display","none");
|
|
|
+ $('.admincp-container-right').css("left","55px");
|
|
|
+ }else{
|
|
|
+ $(".admincp-container-left").css("width","200px");
|
|
|
+ $("#layout-center").css({"position":"absolute","left":"130px","width":(width-130)+"px"});
|
|
|
+ $(".title").attr('title',"")
|
|
|
+ $(".title span").css("display","inline-block");
|
|
|
+ $('.admincp-container-right').css("left","200px");
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+</script>
|
|
|
+<script type="text/javascript">
|
|
|
+ layui.use(['jquery', 'element', 'layer'], function () {
|
|
|
+ var $ = layui.jquery, element = layui.element, layer = layui.layer;
|
|
|
+ $('.layui-tab-content').height($(window).height() - 145);
|
|
|
+ var tab = {
|
|
|
+ add: function (title, url, id) {
|
|
|
+ element.tabAdd('dsTab', {
|
|
|
+ title: title,
|
|
|
+ content: '<iframe width="100%" height="100%" lay-id="' + id + '" frameborder="0" src="' + url + '" scrolling="yes" class="x-iframe"></iframe>',
|
|
|
+ id: id
|
|
|
+ });
|
|
|
+ }, change: function (id) {
|
|
|
+ element.tabChange('dsTab', id);
|
|
|
+ }
|
|
|
+ };
|
|
|
+ $('.admin-nav-item').click(function (event) {
|
|
|
+ var that = $(this);
|
|
|
+ if ($('iframe[src="' + that.attr('href') + '"]')[0]) {
|
|
|
+ tab.change(that.attr('data-id'));
|
|
|
+ event.stopPropagation();
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ if ($('iframe').length == 20) {
|
|
|
+ layer.msg('最多可打开20个标签页');
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ that.css({color: '#fff'});
|
|
|
+ tab.add(that.text(), that.attr('href'), that.attr('data-id'));
|
|
|
+ tab.change(that.attr('data-id'));
|
|
|
+ event.stopPropagation();
|
|
|
+ return false;
|
|
|
+ });
|
|
|
+ $(document).on('click', '.layui-tab-close', function () {
|
|
|
+ $('.layui-nav-child a[data-id="' + $(this).parent('li').attr('lay-id') + '"]').css({color: 'rgba(255,255,255,.7)'});
|
|
|
+ });
|
|
|
+ });
|
|
|
+ $('#gloMenu').on('click', '#navT', function () {
|
|
|
+ var parent = $(this).closest('li');
|
|
|
+ var index = parent.index();
|
|
|
+ if (parent.find('#navC').find('li').length) {
|
|
|
+ if (parent.hasClass('open')) {
|
|
|
+ parent.find('#navC').stop(true).slideUp(300, function () {
|
|
|
+ parent.removeClass('open')
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ var openLi = $('.sidebar-menu').find('li.open');
|
|
|
+ openLi.removeClass('open').find('#navC').stop(true).slideUp(300);
|
|
|
+ parent.addClass('open').find('#navC').stop(true).slideDown(300);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ $('#nav').on('click', '#nav1', function () {
|
|
|
+ var parent = $(this).closest('li');
|
|
|
+ var index = parent.index();
|
|
|
+ if (parent.find('#nav2').find('li').length) {
|
|
|
+ if (parent.hasClass('open')) {
|
|
|
+ parent.find('#nav2').stop(true).slideUp(300, function () {
|
|
|
+ parent.removeClass('open')
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ var openLi = $('.sidebar-menu').find('li.open');
|
|
|
+ openLi.removeClass('open').find('#nav2').stop(true).slideUp(300);
|
|
|
+ parent.addClass('open').find('#nav2').stop(true).slideDown(300);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+</script>
|
|
|
+</body>
|
|
|
+
|
|
|
+
|
|
|
+</html>
|