parent
9917b19811
commit
693424079a
File diff suppressed because one or more lines are too long
@ -0,0 +1,76 @@
|
|||||||
|
*{ padding:0; margin:0;}
|
||||||
|
html{height: 100%;}
|
||||||
|
body{ font-size:12px; min-width:900px; font-family:'微软雅黑';}
|
||||||
|
a{ color:#222; text-decoration:none;}
|
||||||
|
|
||||||
|
.clearfix:after{ clear:both; display:block; content:'';}
|
||||||
|
.clearfix{ zoom:1;}
|
||||||
|
.wrap{ width:1000px; margin:0 auto; }
|
||||||
|
input:focus,textarea:focus{box-shadow:0 0 3px 1px rgba(32, 127, 179, 0.4);outline: 0 none;}
|
||||||
|
/******************************* 其他样式 *******************************/
|
||||||
|
/*错误提示*/
|
||||||
|
.err{ float:left; height:20px; line-height:20px; text-align:right; font-size:12px; width:100%; color:red; display:none; position:absolute; left:0px;}
|
||||||
|
.err img{ margin-top:2px; margin-right:2px;}
|
||||||
|
.err-top40{ top:40px;}
|
||||||
|
.err-top20{ top:20px;}
|
||||||
|
.err-top160{ top:160px;}
|
||||||
|
.err-top90{ top:90px;}
|
||||||
|
/*上传*/
|
||||||
|
#reg_info_file_base64 {filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=image);}
|
||||||
|
/*登录*/
|
||||||
|
.login-box-cen{ width:240px; border:1px solid #cccccc; margin:0px auto 0px; height:318px; border-radius:10px; padding:0 64px; background:#fff;}
|
||||||
|
.login-box-cen-ti{ height:76px; line-height:76px; text-align:center; color:#222222; font-size:16px}
|
||||||
|
.login-box-cen-form{ position:relative;}
|
||||||
|
.login-box-cen-form-input{ float:left; padding-left:20px; border:1px solid #ccc; height:38px; line-height:38px; font-size:14px; color:#999999;}
|
||||||
|
.login-box-cen-form-button{float:left; height:40px; line-height:40px; font-size:14px; color:#fff; text-align:center; background:#207fb3; cursor:pointer;}
|
||||||
|
.login-box-cen-form-ot{ height:30px; line-height:30px; text-align:right; font-size:12px;}
|
||||||
|
.login-box-cen-form-ot span{color:#999999;}
|
||||||
|
.login-box-cen-form-ot a{ color:#207fb3;}
|
||||||
|
|
||||||
|
.w218{ width:218px;}
|
||||||
|
.w238{ width:238px;}
|
||||||
|
.mar-bottom10{ margin-bottom:10px;}
|
||||||
|
/*注册*/
|
||||||
|
.register-box-step{ height:30px; margin:0px auto; width:382px; padding:40px 0;}
|
||||||
|
.register-box-step span{ float:left; line-height:26px; height:30px; width:30px; text-align:center;color:#207fb3; font-size:16px;background: url("register_02.png")/*tpa=http://www.17sucai.com/preview/1266961/2018-07-10/validate/images/register_02.png*/ center top no-repeat;}
|
||||||
|
.register-box-step span.step-active{ color:#fff;background: url("register_01.png")/*tpa=http://www.17sucai.com/preview/1266961/2018-07-10/validate/images/register_01.png*/ center top no-repeat;}
|
||||||
|
.register-box-step em{ float:left; width:130px; background:#207fb3; margin-top:13px; height:2px;}
|
||||||
|
.register-box-step-first{ margin-left:16px;}
|
||||||
|
.register-box-con{ width:380px; padding: 0 310px; background:#fff; padding-bottom:180px;}
|
||||||
|
.register-box-con-ti{ height:114px; line-height:114px; text-align:center; font-size:14px; color:#222222; letter-spacing:1px;}
|
||||||
|
.login-box-cen-form-img{ float:left; height:40px; line-height:40px;overflow:hidden; background:#207fb3;}
|
||||||
|
.login-box-cen-form-mes{ float:left;border:none; height:40px; line-height:40px; text-align:center;font-size:14px; color:#fff; background:#207fb3; cursor:pointer; border-radius:5px;}
|
||||||
|
.register-box-cen-form{ position:relative;}
|
||||||
|
.register-box-cen-form-xieyi{ height:16px; line-height:16px;}
|
||||||
|
.register-box-cen-form-xieyi span{ display:inline-block; position:relative; height:16px; line-height:16px; width:17px; vertical-align:top; margin:0 36px 0 44px; cursor:pointer; background-image:url("register_03.png")/*tpa=http://www.17sucai.com/preview/1266961/2018-07-10/validate/images/register_03.png*/; background-repeat:no-repeat; background-position:0px 0px;}
|
||||||
|
.register-box-cen-form-xieyi span.ok{background-position:-17px 0px;}
|
||||||
|
.register-box-cen-form-xieyi em{display:inline-block; height:16px; line-height:16px;vertical-align:top; font-size:14px;}
|
||||||
|
.register-box-cen-form-xieyi a{ color:#207fb3;}
|
||||||
|
|
||||||
|
.register-box-con2-box{}
|
||||||
|
.register-box-con2-box-left{ height:40px; line-height:40px; text-align:right; float:left; width:293px; color:#222222; font-size:16px;}
|
||||||
|
.register-box-con2-box-left strong{ font-weight: bold;}
|
||||||
|
.register-box-con2-box-right{float:left; width:380px; margin-left:20px; position:relative;}
|
||||||
|
.register-box-con2-box-right .register-box-con2-box-right-text{ font-size:16px; color:#207fb3; margin-left:20px; line-height:40px;}
|
||||||
|
.login-box-cen-form-textarea{float:left; padding-left:20px; border:1px solid #ccc;line-height:38px; font-size:14px; color:#999999; resize:none;}
|
||||||
|
.register-box-con2-box-upload{ position:relative; width:165px; height:98px; float:left;border:1px solid #ccc; margin-bottom:12px; float:left;}
|
||||||
|
.register-box-con2-box-upload .register-box-con2-box-upload-ti{ position:absolute; left:0px; top:0px;width:165px; height:98px; text-align:center; line-height:98px; font-size:18px; color:#207fb3; z-index:9; overflow:hidden; text-align:center; display:table-cell; }
|
||||||
|
.register-box-con2-box-upload .register-box-con2-box-upload-ti img{vertical-align:middle;}
|
||||||
|
.register-box-con2-box-upload input{ position:absolute; left:0px; top:0px;width:165px;z-index:99; opacity:0;filter:alpha(opacity=0);}
|
||||||
|
.register-box-con2-box-pw{ height:25px; line-height:25px; font-size:14px; color:#222222; float:left; width:380px;}
|
||||||
|
|
||||||
|
.register-box-con-good{ padding:20px 0 410px;color:#222222l}
|
||||||
|
.register-box-con-good img{ display:block; margin:0 auto;}
|
||||||
|
.register-box-con-good-p1{ font-size:18px;padding:40px 0 20px; text-align:center; line-height:20px;font-weight:500;}
|
||||||
|
.register-box-con-good-p2{ font-size:14px;text-align:center; line-height:26px;}
|
||||||
|
|
||||||
|
.w358{ width:358px;}
|
||||||
|
.w228{ width:228px;}
|
||||||
|
.w120{ width:120px;}
|
||||||
|
.w380{ width:380px;}
|
||||||
|
.w278{ width:278px;}
|
||||||
|
.h88{ height:88px;}
|
||||||
|
.mar-top50{ margin-top:50px;}
|
||||||
|
.mar-left10{ margin-left:10px;}
|
||||||
|
.mar-bottom20{ margin-bottom:20px;}
|
||||||
|
.bitian{ color:#dc2b2b;}
|
@ -0,0 +1,70 @@
|
|||||||
|
//date: 2016-11-16 author: dgx note:必填正则验证工具
|
||||||
|
function tbdValidate(elelist,objs){
|
||||||
|
var errlen=0;//错误个数
|
||||||
|
var errlist=[];//错误输入框ID
|
||||||
|
for(var i=0;i<elelist.length;i++){ //失去焦点操作
|
||||||
|
(function(eleinput,eletext,rule){
|
||||||
|
document.getElementById(eleinput).onblur=function(){
|
||||||
|
var intval=this.value.replace(/(^\s*)|(\s*$)/g, "");
|
||||||
|
for(var j=0;j<rule.length;j++){
|
||||||
|
var resreg=rule[j].reg.test(intval);
|
||||||
|
if(resreg){
|
||||||
|
document.getElementById(eletext).style.display="none";
|
||||||
|
}else{
|
||||||
|
document.getElementById(eletext).innerHTML=rule[j].text;
|
||||||
|
document.getElementById(eletext).style.display="block";
|
||||||
|
break;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
})(elelist[i].eleinput,elelist[i].eletext,elelist[i].rule);
|
||||||
|
};
|
||||||
|
document.getElementById(objs.elesubmit).onclick=function(){//提交操作
|
||||||
|
errlen=0;
|
||||||
|
errlist=[];
|
||||||
|
for(var i=0;i<elelist.length;i++){
|
||||||
|
(function(eleinput,eletext,rule){
|
||||||
|
var intval=document.getElementById(eleinput).value.replace(/(^\s*)|(\s*$)/g, "");
|
||||||
|
for(var j=0;j<rule.length;j++){
|
||||||
|
var resreg=rule[j].reg.test(intval);
|
||||||
|
if(resreg){
|
||||||
|
document.getElementById(eletext).style.display="none";
|
||||||
|
}else{
|
||||||
|
document.getElementById(eletext).innerHTML=rule[j].text;
|
||||||
|
document.getElementById(eletext).style.display="block";
|
||||||
|
errlen+=1;
|
||||||
|
errlist.push(eleinput);
|
||||||
|
break;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
})(elelist[i].eleinput,elelist[i].eletext,elelist[i].rule);
|
||||||
|
};
|
||||||
|
if(errlen==0){//回调
|
||||||
|
objs.funsubmit();
|
||||||
|
}else{
|
||||||
|
objs.funerr();
|
||||||
|
objs.funerrlist(errlist);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
//date: 2016-11-17 author: dgx note:非必填正则验证工具
|
||||||
|
function tbdnoValidate(elelist){
|
||||||
|
for(var i=0;i<elelist.length;i++){ //失去焦点操作
|
||||||
|
(function(eleinput,eletext,rule){
|
||||||
|
document.getElementById(eleinput).onblur=function(){
|
||||||
|
var intval=this.value.replace(/(^\s*)|(\s*$)/g, "");
|
||||||
|
for(var j=0;j<rule.length;j++){
|
||||||
|
var resreg=rule[j].reg.test(intval);
|
||||||
|
if(resreg){
|
||||||
|
document.getElementById(eletext).style.display="none";
|
||||||
|
}else{
|
||||||
|
document.getElementById(eletext).innerHTML=rule[j].text;
|
||||||
|
document.getElementById(eletext).style.display="block";
|
||||||
|
this.value="";
|
||||||
|
break;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
})(elelist[i].eleinput,elelist[i].eletext,elelist[i].rule);
|
||||||
|
};
|
||||||
|
};
|
@ -0,0 +1,95 @@
|
|||||||
|
//注册-填写身份信息 上传
|
||||||
|
var reg_info_file=document.getElementById("reg_info_file");
|
||||||
|
reg_info_file.onchange=function(){
|
||||||
|
if(window.FileReader){//ie10 ie10+ w3c
|
||||||
|
var file = reg_info_file.files[0];
|
||||||
|
//console.log(file.size);
|
||||||
|
//console.log(file.type);
|
||||||
|
if(/(image\/jpeg)|(image\/png)/.test(file.type)){
|
||||||
|
$("#reg_info_file_text").hide();
|
||||||
|
}else{
|
||||||
|
$("#reg_info_file_text").html('支持图片格式JPG/PNG').show();
|
||||||
|
return false;
|
||||||
|
};
|
||||||
|
if(file.size<2*1024*1024){
|
||||||
|
$("#reg_info_file_text").hide();
|
||||||
|
}else{
|
||||||
|
$("#reg_info_file_text").html('图片大小不超过2M').show();
|
||||||
|
return false;
|
||||||
|
};
|
||||||
|
|
||||||
|
var fr = new FileReader();
|
||||||
|
fr.readAsDataURL(file);
|
||||||
|
$("#reg_info_file_base64").removeAttr("width");
|
||||||
|
$("#reg_info_file_base64").removeAttr("height");
|
||||||
|
fr.onloadend = function(e) {
|
||||||
|
$("#reg_info_file_w").hide();
|
||||||
|
$("#reg_info_file_base64").show();
|
||||||
|
$("#reg_info_file_base64").attr("src",e.target.result);
|
||||||
|
$("#reg_info_file_base64")[0].onload=function(){
|
||||||
|
var upimgw=$("#reg_info_file_base64").width();
|
||||||
|
var upimgh=$("#reg_info_file_base64").height();
|
||||||
|
$("#reg_info_file_base64").attr("width",imgPercentScale(165,98,upimgw,upimgh).w);
|
||||||
|
$("#reg_info_file_base64").attr("height",imgPercentScale(165,98,upimgw,upimgh).h);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}else{ //ie9-
|
||||||
|
$("#reg_info_file_w").hide();
|
||||||
|
$("#reg_info_file_base64").show();
|
||||||
|
var sFilter='filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale,src="';
|
||||||
|
reg_info_file.select();
|
||||||
|
reg_info_file.blur();
|
||||||
|
var src = document.selection.createRange().text;
|
||||||
|
//$("#reg_info_file_base64")[0].filters.item('DXImageTransform.Microsoft.AlphaImageLoader').src = src;
|
||||||
|
$("#reg_info_file_base64")[0].src=src;
|
||||||
|
$("#reg_info_file_base64")[0].onload=function(){
|
||||||
|
var upimgw=$("#reg_info_file_base64").width();
|
||||||
|
var upimgh=$("#reg_info_file_base64").height();
|
||||||
|
$("#reg_info_file_base64").attr("width",imgPercentScale(165,98,upimgw,upimgh).w);
|
||||||
|
$("#reg_info_file_base64").attr("height",imgPercentScale(165,98,upimgw,upimgh).h);
|
||||||
|
};
|
||||||
|
alert("名片上传不被浏览器支持,请更换浏览器打开网站");
|
||||||
|
};
|
||||||
|
};
|
||||||
|
//date: 2016-12-5 author: 杜关兴 note: 图片比例缩放算法
|
||||||
|
/*
|
||||||
|
boxw:容器宽度
|
||||||
|
boxh:容器高度
|
||||||
|
imgw:图片宽度
|
||||||
|
imgh:图片高度
|
||||||
|
*/
|
||||||
|
function imgPercentScale(boxw,boxh,imgw,imgh){
|
||||||
|
var res={};
|
||||||
|
var wper=imgw/boxw;
|
||||||
|
var hper=imgh/boxh;
|
||||||
|
if(wper<=1 && hper<1){
|
||||||
|
res.w=imgw;
|
||||||
|
res.h=imgh;
|
||||||
|
return res;
|
||||||
|
};
|
||||||
|
if(wper>1 && hper<1){
|
||||||
|
res.w=boxw;
|
||||||
|
var rhper=boxw/imgw;
|
||||||
|
res.h=imgh*rhper;
|
||||||
|
return res;
|
||||||
|
};
|
||||||
|
if(wper<=1 && hper>1){
|
||||||
|
res.h=boxh;
|
||||||
|
var rwper=boxh/imgh;
|
||||||
|
res.w=imgw*rwper;
|
||||||
|
return res;
|
||||||
|
};
|
||||||
|
if(wper>1 && hper>1){
|
||||||
|
if(wper>=hper){
|
||||||
|
res.w=boxw;
|
||||||
|
var rhper=boxw/imgw;
|
||||||
|
res.h=imgh*rhper;
|
||||||
|
return res;
|
||||||
|
}else{
|
||||||
|
res.h=boxh;
|
||||||
|
var rwper=boxh/imgh;
|
||||||
|
res.w=imgw*rwper;
|
||||||
|
return res;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
Loading…
Reference in new issue