//留言锚点 document.write(''); document.write(''); $(document).ready(function(e) { //初始化工作 var win_h = $(window).height(); var win_w = $(window).width(); var open_wins_h = $('.open_wins').height(); var open_wins_w = $('.open_wins').width(); var doc_h = $(document).height(); open_wins_css_l = (win_w-open_wins_w)/2; open_wins_css_t = (win_h-open_wins_h)/2; var msly_off = $('#tc_liuyans').offset(); $('.open_wins').css({left:msly_off.left,top:msly_off.top,'margin':'0px'}); //开始 var open_wins_clone = $('.open_wins').clone(); $('.open_wins').remove(); $("body").append(open_wins_clone); //结束 $("body").append("
"); $('.open_backs').css({'opacity': '0.8','filter':'Alpha(opacity=80)','height':doc_h,'width':win_w}); //留言弹窗关闭按钮 $('#fcgb').click(function(){ $('.open_backs').fadeOut('fast'); $('.open_wins').animate({width:120,height:40,left:msly_off.left,top:msly_off.top},'fast',function(){ var win_h = $(window).height(); var win_w = $(window).width(); open_wins_css_l = (win_w-open_wins_w)/2; open_wins_css_t = (win_h-open_wins_h)/2; $('.open_wins').hide(); $('#gbookdh').fadeTo('fast',0.5,function(){ $('#gbookdh').fadeTo('fast',1); }); }); }); //留言弹窗开启按钮 $('#tc_tels').click(function(){ $('.open_wins').css({width:120,height:40,left:msly_off.left,top:msly_off.top}); $('.open_backs').fadeTo('fast',0.8); $('.open_wins').show(); $('.open_wins').animate({width:open_wins_w,height:open_wins_h,left:open_wins_css_l,top:open_wins_css_t},'fast'); }); //留言弹窗开启按钮 $('#tc_liuyans').click(function(){ $('.open_wins').css({width:120,height:40,left:msly_off.left,top:msly_off.top}); $('.open_backs').fadeTo('fast',0.8); $('.open_wins').show(); $('.open_wins').animate({width:open_wins_w,height:open_wins_h,left:open_wins_css_l,top:open_wins_css_t},'fast'); }); //点击事件 $('#liuyan_text').focus(function(){ $('.liuyan_notice').fadeIn('fast'); }); $('#liuyan_text').focusout(function(){ $('.liuyan_notice').fadeOut('fast'); }); //获得快捷文字 $('.liuyan_notice ul li').click(function(){ var this_val = $(this).text(); $('.textarea').append(this_val+'\r\n'); }); //窗口变化 $(window).resize(function(){ var win_h = $(window).height(); var win_w = $(window).width(); open_wins_css_l = (win_w-open_wins_w)/2; open_wins_css_t = (win_h-open_wins_h)/2; $('.open_wins').css({left:open_wins_css_l,top:open_wins_css_t}); $('.open_backs').css({'width':win_w}); }); }); document.write(''); document.write('
'); document.write('
'); document.write('
  • '); document.write('
  • '); document.write('
    '); document.write('
    '); document.write(''); document.write('');