$(document).ready(function(e) { var default_height=49; //默认切片高度 var default_swf="http://tb.53kf.com/webCompany.php?arg=10066661&style=1"; //默认商务通点击连接 var default_index="http://www.tyv1.com"; //默认商务通点击连接 var default_dianping="https://www.dianping.com/shop/4878602"; //大众点评 var default_kp="http://www.tyv1.com/showcase.aspx"; //客片欣赏 var bodyHtml=""; var object_a=$(""); object_a.attr("href",default_swf); object_a.attr("target","_blank"); object_a.css("display","block"); object_a.width(1200); object_a.height(default_height); var object_b=$(""); object_b.attr("href",default_index); object_b.attr("target","_blank"); object_b.css("display","block"); object_b.width("100%"); object_b.height(default_height); var object_c=$(""); object_c.attr("href",default_dianping); object_c.attr("target","_blank"); object_c.css("display","block"); object_c.width("100%"); object_c.height(default_height); var object_d=$(""); object_d.attr("href",default_kp); object_d.attr("target","_blank"); object_d.css("display","block"); object_d.width("100%"); object_d.height(default_height); var object_submit_top=new Array(); object_submit_top[0]=100; object_submit_top[1]=80; object_submit_top[2]=190; object_submit_top[3]=30; var object_submit=$('
 
'); object_submit.css("display","block"); object_submit.width("100%"); object_submit.height(default_height); var video=$('
'); var footer_link=$("
"); var footer_a=$(""); footer_a.attr("href",default_index); footer_a.attr("target","_blank"); footer_link.addClass("footer-box"); footer_link.append(footer_a.clone()); footer_a.attr("href",default_swf); footer_link.append(footer_a.clone()); for(var i=1;i<=50;i++) { var num; if(i<10) num="0"+i; else num=i; var parentdiv=$('
'); parentdiv.height(default_height); parentdiv.css("background-image","url(images/index_"+num+".jpg)"); parentdiv.css("background-repeat","no-repeat"); parentdiv.css("background-position","center"); switch(i) { case 02:parentdiv.height(48);break; case 05:parentdiv.height(48);break; case 08:parentdiv.height(48);break; case 11:parentdiv.height(48);break; case 14:parentdiv.height(48);break; case 17:parentdiv.height(48);break; case 20:parentdiv.height(48);break; case 23:parentdiv.height(48);break; case 25:parentdiv.height(48);break; case 28:parentdiv.height(48);break; case 31:parentdiv.height(48);break; case 34:parentdiv.height(48);break; case 37:parentdiv.height(48);break; case 40:parentdiv.height(48);break; case 43:parentdiv.height(48);break; case 46:parentdiv.height(48);break; case 49:parentdiv.height(48);break; } $("#zhuanti").append(parentdiv); } $("input.submitDivName").live("blur",function(){ if($(this).val()=="") $(this).val("姓名"); }); $("input.submitDivName").live("focus",function(){ if($(this).val()=="姓名") $(this).val(""); }); $("input.submitDivTel").live("blur",function(){ if($(this).val()=="") $(this).val("电话"); }); $("input.submitDivTel").live("focus",function(){ if($(this).val()=="电话") $(this).val(""); }); $(".submitDivButton").live("click", function () { var name = $(this).parent().find("input.submitDivName").val(); var tel = $(this).parent().find("input.submitDivTel").val(); if (name == '姓名' || name == '' || name == null) { alert("请填写您的姓名"); return; } if (tel == '电话' || tel == '' || tel == null) { alert("请填写您的手机号码"); return; } var regPartton=/1[3-8]+\d{9}/; if(!regPartton.test(tel)) { alert("对不起,您输入的的手机号码有误!"); return; } user_submit(name, tel); }); }); function user_submit(name, tel) { var user=new Object(); user.userName=name; user.tel=tel; user.hq_time="2000-1-1"; user.remark=""; $.ajax({ type: "post", url: "/tools/submit_ajax.ashx?action=add_receive", //data: "{'userName':'" + name + "','tel':'" + tel + "'}", data: JSON.stringify(user), success: function (data) { if(data.stutic=="success") alert("提交成功!"); else alert(data.msg); }, error: function (data) { alert("对不起,提交失败,请检查您输入的信息是否有误!"); }, dataType: "json" }); }