$(function(){ $(".rihk img").click(function(){ $("html,body").stop().animate({"scrolltop":0}) }) $("#kinmaxshow").kinmaxshow(); //if($(".oijs li").length>0){$(".oijs li").width(parseint(1200/$(".oijs li").length))} }) $(window).load(function () { if($(".ojot li").length>0){ $(".ojot").jcarousellite({ btnnext: ".ghsu", // btnprev: ".lmoi", speed: 800, auto:800, visible:3 }); } if($(".hiuo li").length>0){ $(".hiuo").jcarousellite({ btnnext: ".rigt", btnprev: ".letg", speed: 800, auto:800, visible:4 }); $(".jues").jcarousellite({ btnnext: ".rige", btnprev: ".lete", speed: 800, auto:800, visible:5 }); $(".zfco").jcarousellite({ btnnext: ".rigs", btnprev: ".lets", speed: 800, auto:800, visible:4 }); } }); function togglecode(obj, codeurl) { $(obj).attr("src", codeurl + "?time=" + math.random()); } function f_check2() { var txt_0 = $("#jobtitle"); if ($.trim(txt_0.val()) == "") { alert("请输入职位!"); txt_0.val("").focus(); return false; } var txt_1 = $("#txt_name"); if ($.trim(txt_1.val()) == "") { alert("请输入姓名!"); txt_1.val("").focus(); return false; } var txt_2 = $("#txt_phone"); if ($.trim(txt_2.val()) == "") { alert("请输入联系方式!"); txt_2.val("").focus(); return false; }else if (!validate2.cellphone()) { alert("联系方式格式错误!正确格式0577-88888888"); txt_2.focus(); return false; } var txt_5 = $("#txt_email"); if($.trim(txt_5.val()) != ""){ var reg = /^([a-za-z0-9]+[_|\_|\.]?)*[a-za-z0-9]+@([a-za-z0-9]+[_|\_|\.]?)*[a-za-z0-9]+\.[a-za-z]{2,3}$/; if (!reg.test($(txt_5).val())) { alert("邮箱格式错误!"); $(txt_5).focus(); return false; } } var txt_3 = $("#txt_content"); if ($.trim(txt_3.val()) == "") { alert("请输入简历!"); txt_3.val("").focus(); return false; } var txt_4 = $("#txt_code"); if ($.trim(txt_4.val()) == "") { alert("请输入验证码!"); txt_4.val("").focus(); return false; } return true; } function f_check() { var txt_0 = $("#txt_title"); if ($.trim(txt_0.val()) == "") { alert("请输入标题!"); txt_0.focus(); return false; } var txt_1 = $("#txt_name"); if ($.trim(txt_1.val()) == "") { alert("请输入姓名!"); txt_1.focus(); return false; } var txt_2 = $("#txt_email"); if ($.trim(txt_2.val()) == "") { alert("请输入邮箱!"); txt_2.focus(); return false; } else { //验证邮箱格式 var reg = /^([a-za-z0-9]+[_|\_|\.]?)*[a-za-z0-9]+@([a-za-z0-9]+[_|\_|\.]?)*[a-za-z0-9]+\.[a-za-z]{2,3}$/; if (!reg.test($(txt_2).val())) { alert("邮箱格式错误!"); $(txt_2).focus(); return false; } } var txt_3 = $("#txt_tel"); if ($.trim(txt_3.val()) == "") { alert("请输入电话!"); txt_3.focus(); return false; } else if (!validate.cellphone()) { alert("电话格式错误!电话正确格式0577-88888888"); txt_3.focus(); return false; } var txt_4 = $("#txt_content"); if ($.trim(txt_4.val()) == "") { alert("请输入内容!"); txt_4.focus(); return false; } var txt_5 = $("#txt_code"); if ($.trim(txt_5.val()) == "") { alert("请输入验证码!"); txt_5.focus(); return false; } return true; } var validate = { istel: function (s) { var patrn = /^0\d{2,3}-?\d{7,8}$/ if (!patrn.test(s)) return false return true }, ismobile: function (value) { var validatereg = /^((\+?86)|(\(\+86\)))?1\d{10}$/; return validatereg.test(value); }, cellphone: function () { var cellphonenumber = $("#txt_tel").val(); if (validate.ismobile(cellphonenumber) || validate.istel(cellphonenumber)) { return true; } else { return false; } }, telephone: function () { } } var validate2 = { istel: function (s) { var patrn = /^0\d{2,3}-?\d{7,8}$/ if (!patrn.test(s)) return false return true }, ismobile: function (value) { var validatereg = /^((\+?86)|(\(\+86\)))?1\d{10}$/; return validatereg.test(value); }, cellphone: function () { var cellphonenumber = $("#txt_phone").val(); if (validate2.ismobile(cellphonenumber) || validate2.istel(cellphonenumber)) { return true; } else { return false; } }, telephone: function () { } } //收藏本站 function addfavorite(title, url) { try { window.external.addfavorite(url, title); } catch (e) { try { window.sidebar.addpanel(title, url, ""); } catch (e) { alert("抱歉,您所使用的浏览器无法完成此操作。\n\n加入收藏失败,请使用ctrl+d进行添加"); } } }