','取消'], btnAlign: 'c', // 按钮居中 area: 'auto', id: '', shade: .48, moveType: 1, content: $('#liuyan1'), btn1:function(index){ layer.load(); //上传头像 var tx_src = $('.txlist .active').children('.box').children('.pic').children('.middleCenter').attr('src'); $.ajax({ type: 'POST', url : "/edit_tx", data: {'tx_src':tx_src}, dataType: "JSON", success: function(res) { $('#srcimgurl').attr('src',tx_src); layer.closeAll(); layer.msg(res.msg,{ icon: res.icon, time: 800 }); }, error: function(e) { layer.closeAll(); } }); } }); }); $(".showliuyan").click(function() { privacy = layer.open({ type: 1, title: false, //不显示标题栏 closeBtn: 1, area: 'auto', shade: 0.48, id: '', //设定一个id,防止重复弹出 btn: ['提交'], btnAlign: 'submit', moveType: 1, //拖拽模式,0或者1 content: $('#liuyan'), btn1:function () { layer.load(); var data = $('#liuyan_form').serializeArray(); $.ajax({ type: 'POST', url : "/submitmessage", data:{'data':data}, dataType: "JSON", success: function(res) { layer.closeAll(); if(res.code == 200){ _tips = layer.open({ title:'提示', content: "

" + res.msg +"

", btn: ['确认'], btnAlign: 'c', // 按钮居中 area: 'auto', shade: .48, move: false, btn1:function(index){ window.location.reload(); } }); }else{ layer.closeAll(); _tips = layer.open({ title:'提示', content: "

" + res.msg +"

", btn: ['确认'], btnAlign: 'c', // 按钮居中 area: 'auto', shade: .48, move: false, }); } }, error: function(e) { layer.closeAll(); } }); } }); }) $(".showdianhua").click(function() { privacy1 = layer.open({ type: 1, title: false, //不显示标题栏 closeBtn: 1, area: 'auto', shade: 0.48, id: '', //设定一个id,防止重复弹出 moveType: 1, //拖拽模式,0或者1 content: $('.tanchu .hover1'), }); }) $(".showshiyan").click(function() { privacy2 = layer.open({ type: 1, title: false, //不显示标题栏 closeBtn: 1, area: 'auto', shade: 0.48, id: '', //设定一个id,防止重复弹出 moveType: 1, //拖拽模式,0或者1 content: $('.tanchu .hover2'), }); }) $(".showfaq").click(function() { privacy3 = layer.open({ type: 1, title: false, //不显示标题栏 closeBtn: 1, area: 'auto', shade: 0.48, id: '', //设定一个id,防止重复弹出 moveType: 1, //拖拽模式,0或者1 content: $('.tanchu .hover3'), }); }); $(".dingyue").click(function() { privacy4 = layer.open({ type: 1, title: false, //不显示标题栏 closeBtn: 1, area: 'auto', shade: 0.48, id: '', //设定一个id,防止重复弹出 moveType: 1, //拖拽模式,0或者1 content: $('#dingyue'), }); }) }) /* 鼠标特效 */ var a_idx = 0; var words = document.getElementById('words').value; //console.log(words); //console.log(typeof (words)); words=words.split(','); //console.log(words); jQuery(document).ready(function($) { $("body").click(function(e) { //生物学,细胞学,酶学 ,DMPK,ADME、PK、PK/PD,药效学、动物模型, CDX; 毒理学; 化合物;试剂; 移植瘤;免疫学 // var a = new Array("生物学", "细胞学", "酶学", "DMPK", "ADME", "PK", "PK/PD", "药效学", "动物模型", "CDX", "毒理学", "化合物", "试剂", "移植瘤", "免疫学"); var a = words; var $i = $("").text(a[a_idx]); a_idx = (a_idx + 1) % a.length; var x = e.pageX, y = e.pageY; $i.css({ "z-index": 999999999999999999999999999999999999999999999999999999999999999999999, "top": y - 20, "left": x, "position": "absolute", /*"font-weight": "bold",*/ "color": "#53fa42" }); $("body").append($i); $i.animate({ "top": y - 180, "opacity": 0 }, 1500, function() { $i.remove(); }); }); });