Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(function(){
- // resizable
- $('.formdiv textarea').attr('class','resizable');
- //$('input[type=file]').wrap("<div class=filediv></div>");
- // всплывающие подсказки
- $('body').mousemove(function(e){
- X=e.pageX;
- Y=e.pageY;
- });
- $('.tlt').mouseover(function(){
- tlt=$(this).attr('tlt');
- $('#tlt').css({opacity:0.0})
- .html("<div class='arr pa'></div>"+tlt)
- .show()
- .animate({opacity:1.0},300);
- }).mousemove(function(){
- $('#tlt').css({top:Y-($('#tlt').height()+30)+'px',left:X-15+'px'});
- }).mouseleave(function(){
- $('#tlt').hide();
- });
- // menutop
- $('.menutop .item').mouseenter(function(){
- if($(this).attr('class')!='item open fl'){
- $(this).css(
- {
- border:"1px solid #818896",
- background:"#969fb3"
- }
- ).animate({opacity:1.0},200);
- }
- }).mouseleave(function(){
- if($(this).attr('class')!='item open fl'){
- $(this).css(
- {
- border:"1px solid #969fb3",
- background:"none"
- }
- ).animate({opacity:0.5},100);
- }
- });
- // menutop
- $('#menu a').mouseover(function(){
- if($(this).attr('class')!='open'){
- var name=$(this).attr('name');
- if(name!=''){
- if(typeof(oldname)=='undefined' || name!=oldname){
- $('#menu div[class=]').slideUp(200);
- $('#menu div[name='+name+']').slideDown(200);
- oldname=name;
- }
- }
- }
- else{
- $('#menu div[class=]').slideUp(200);
- oldname=name;
- }
- });
- $('#menu div[name='+$('#menu a.open').attr('name')+']').show().attr('class','opened');
- // krowki
- zInd=10;
- $('#krowki .item').each(function(){
- $(this).css('zIndex',zInd);
- zInd-=1;
- }).mouseover(function(){
- $(this).css(
- {
- background:"#969fb3",
- border:"1px solid #7a8191"
- }
- );
- $(this).find('.l').css({backgroundPosition:'0px -69px'});
- $(this).find('.r').css({backgroundPosition:'0px -23px'});
- }).mouseleave(function(){
- $(this).css(
- {
- background:"#6c7488",
- border:"1px solid #585e6e"
- }
- );
- $(this).find('.l').css({backgroundPosition:'0px -92px'});
- $(this).find('.r').css({backgroundPosition:'0px 0px'});
- });
- // toggle menu
- $('#togglemenu').click(function(){
- if($('.left').css('display')=='block'){
- $('.left').slideUp(100);
- $('.right').delay(120).animate({width:'1165px'},300);
- $(this).css({backgroundPosition:'0px -41px'});
- }
- else{
- $('.right').animate({width:'870px'},300);
- $('.left').delay(320).slideDown(100);
- $(this).css({backgroundPosition:'0px 0px'});
- }
- });
- });
Add Comment
Please, Sign In to add comment