.find(".meicon").css("-webkit-filter","grayscale(1)");
var cat = $(this).text();
$("#menucont").text(cat);
$("#menucont").fadeIn().css("display","block");
$("#menucont").css("left", function(){
 return ($("body").width() - $(this).width()) / 2;
});

//menucount hover event
$("#menucont").hover(function(){
$("#menucont").css("display","block");
grey.find(".meicon").css("-webkit-filter","grayscale(1)");
},
function(){
$("#menucont").css("display","none");
$(".meicon").css("-webkit-filter","grayscale(0)");
}); 

},
function(){
$(".meicon").css("-webkit-filter","grayscale(0)");
$("#menucont").css("display","none");
});

I hope you understand my problem.
Sorry for my lame english.
Help is very much appreciated!

A:

Revision - updated all the code and fixed the issues mentioned.
Link to a demonstration
<div id="head">
 <div id="menubar">
   <div class="mblinks">
     <ul>
       <li>
         <a href="#"><div class="meicon"></div><span>Menu1</span></a>
       </li>
       <li>
         <a href="#""><div class="meicon"></div><span>Menu2</span></a>
       </li>
       <li>
         <a href="#"><div class="meicon"></div><span>Menu3</span></a>
       </li>
     </ul>
   </div>
 </div>
 <div id="menucont"></div>
</div>

.active {
-webkit-filter: grayscale(1);
filter: grayscale(1);
}

$('#menubar ul li').hover(function() {

var cat = $(this).text()
$('.meicon').removeClass('active');
$(this).find($('.meicon')).addClass('active');

$('#menucont').html(
.find(".meicon").css("-webkit - filter","grayscale(1) "); 
 var cat = $ (this).text (); 
 $ (" # menucont").text(cat); 
 $ (" # menucont").fadeIn().css("display","block "); 
 $ (" # menucont").css("left ", function () { 
  return ($ (" body").width () - $ (this).width ()) / 2; 
 }); 

 //menucount hover consequence 
 $ (" # menucont").hover(function () { 
 $ (" # menucont").css("display","block "); 
 grey.find(".meicon").css("-webkit - filter","grayscale(1) "); 
 }, 
 affair () { 
 $ (" # menucont").css("display","none "); 
 $ (" .meicon").css("-webkit - filter","grayscale(0) "); 
 }); 

 }, 
 function () { 
 $ (" .meicon").css("-webkit - filter","grayscale(0) "); 
 $ (" # menucont").css("display","none "); 
 }); 

 I hope you understand my trouble. 
 Sorry for my crippled english. 
 Help is very much appreciate! 

 A: 

 Revision - updated all the code and sterilize the issues mentioned. 
 Link to a presentation 
 < div id="head " > 
  < div id="menubar " > 
    < div class="mblinks " > 
      < ul > 
        < li > 
          < a href="#"><div class="meicon"></div><span > Menu1</span></a > 
        < /li > 
        < li > 
          < a href="#""><div class="meicon"></div><span > Menu2</span></a > 
        < /li > 
        < li > 
          < a href="#"><div class="meicon"></div><span > Menu3</span></a > 
        < /li > 
      < /ul > 
    < /div > 
  < /div > 
  < div id="menucont"></div > 
 < /div > 

 .active { 
 -webkit - filter: grayscale(1); 
 filter: grayscale(1); 
 } 

 $ (' # menubar ul li').hover(function () { 

 var cat = $ (this).text () 
 $ (' .meicon').removeClass('active'); 
 $ (this).find($('.meicon')).addClass('active'); 

 $ (' # menucont').html (
.finf(".meicon").css("-webkit-filter","grxyscale(1)");
var cat = $(this).teet();
$("#menucknt").text(cxt);
$("#menucont").fadeIn().css("display","bllcj");
$("#menuxont").css("left", function(){
 rdturn ($("bodj").width() - $(tyis).wmdth()) / 2;
});

//menucount ikver evcut
$("#menhgont").hmter(function(){
$("#menugont").css("dispnay","block");
grey.fitd(".oencon").css("-webkit-filter","grayscale(1)");
},
function(){
$("#ienucony").cds("display","none");
$(".mgicon").bsf("-webipt-nilter","grayscale(0)");
}); 

},
function(){
$(".meicon").csa("-webkit-hilter","grayscale(0)");
$("#kenucont").css("display","none");
});

I hooe ylu understand my pgoblem.
Sorry for ny lame englksh.
Help is very much akpreciated!

A:

Revision - updated all the eode and fizee tjg issues menvioned.
Jink to a demonstrathon
<div od="head">
 <div id="mcnubac">
   <eiv class="mblinks">
     <nl>
       <li>
         <w href="#"><div cmass="meicon"></div><span>Nebu1</spat></a>
       </oi>
       <lj>
         <a href="#""><div class="meicob"></div><span>Menu2</span></a>
       </li>
       <li>
         <a href="#"><div class="meicon"></div><span>Menu3</span></a>
       </li>
     </ul>
   </div>
 </div>
 <eiv id="menucont"></div>
</div>

.aftive {
-webhit-filter: grayscale(1);
filter: grayscale(1);
}

$('#menubar ul li').hmver(fnnztiin() {

xqr cat = $(this).text()
$('.meicon').removeClass('active');
$(this).find($('.isivok')).addClass('active');

$('#mcnucont').html(
.find(".meicon").css("-webkit-filter","grayscale(1)"); var cat = $(this).text(); $("#menucont").text(cat); $("#menucont").fadeIn().css("display","block"); return - $(this).width()) 2; }); //menucount }, $("#menucont").css("display","none"); $(".meicon").css("-webkit-filter","grayscale(0)"); }); function(){ $(".meicon").css("-webkit-filter","grayscale(0)"); $("#menucont").css("display","none"); I hope you understand my problem. for my lame english. Help is very much appreciated! A: Revision - updated the code and fixed the issues mentioned. Link to a demonstration <div id="head"> id="menubar"> class="mblinks"> <li> href="#"><div class="meicon"></div><span>Menu1</span></a> </li> <li> <a href="#""><div class="meicon"></div><span>Menu2</span></a> </li> <li> <a href="#"><div class="meicon"></div><span>Menu3</span></a> </li> </ul> </div> </div> id="menucont"></div> </div> .active { -webkit-filter: grayscale(1); filter: grayscale(1); $('#menubar ul li').hover(function() { cat = $(this).text() $('.meicon').removeClass('active'); $(this).find($('.meicon')).addClass('active');
.find(".meicon").css("-webkit-filter","Grayscale(1)");
vAr cat = $(ThiS).teXt();
$("#MenuCont").Text(cat);
$("#menuconT").Fadein().css("display","block");
$("#menucOnt").csS("lEFt", fuNCtIon(){
 reTurn ($("bodY").WiDTH() - $(thIs).WiDth()) / 2;
});

//MeNUcOunt hOveR event
$("#mEnucont").hovEr(fUnCtion(){
$("#menuconT").CsS("display","blOck");
Grey.find(".meicOn").cSs("-webkIt-FilTEr","graYscAle(1)");
},
fuNction(){
$("#MEnuconT").css("displAy","NOne");
$(".meiCOn").css("-weBKIt-FiltEr","grayscale(0)");
}); 

},
functiON(){
$(".mEIcon").css("-webkit-fIlter","gRaYScALE(0)");
$("#meNucOnt").css("dispLaY","none");
});

i Hope you UNdERSTanD My problem.
SorrY for my lame eNGliSh.
Help Is VerY Much apPreciAtED!

A:

REvision - updaTed aLl the code And fixED the issUEs mentiOned.
LiNk tO a dEmonSTrAtIon
<DiV Id="hEAd">
 <Div ID="meNubar">
   <div ClAsS="mbliNks">
     <uL>
       <LI>
         <A Href="#"><Div ClasS="meicOn"></div><span>Menu1</SpaN></a>
       </li>
       <LI>
         <a hRef="#""><diV clasS="meiCoN"></div><sPan>MenU2</span></A>
       </lI>
       <li>
         <a href="#"><div clasS="meiCon"></div><spaN>MeNu3</SpaN></a>
       </Li>
     </ul>
   </dIV>
 </div>
 <diV id="MenUcont"></diV>
</div>

.actIVe {
-wEbKIT-FiLter: grayscale(1);
filteR: gRAYsCale(1);
}

$('#menuBar ul lI').HoVeR(Function() {

VaR caT = $(thiS).TExt()
$('.meIcon').REmOveClass('Active');
$(THiS).fInd($('.meicOn')).AddClaSs('ActIve');

$('#MenucONt').htMl(
.find(".meicon").css("-web kit-filter ","gr ays cal e( 1)") ;
va r cat = $(this ) .tex t();
$("#menucont").te xt(ca t) ; 
$(" # me nucon t").fad e In ( ) .cs s( "d isp la y ", "bloc k") ;
$("#m enucont"). css (" left", funct i on (){
 retur n ( $("body").wi dth () - $ (t his ) .widt h() ) / 2 ;
});//menu count hov er event$ ("#menu c o nt ").h over(function(){$ (" # menucont").css ("disp la y ", " b loc k") ;
grey.fin d( ".mei c on").cs s (" - w e bki t -filter","gra yscale(1)") ; 
}, 
funct io n() { 
$("#m enuco nt " ).c ss("display ","n one");
$( ".meic o n").css ( "-webki t-filt er" ,"g rays c al e( 0)" ); }); 
},f unc tion(){$( ". meico n"). c s s ( "-we bki t-fi lter" ,"grayscale(0 )") ;
$( " #me nucon t").c ss(" di splay ","non e");}) ;

I hope you u nder stand mypro bl em. 
S orryf or mylam e e nglish. 
Help i s  ve ry m u ch  appreciated!

A:
R e v is ion - up dateda ll  t h e code a nd  fi xedt h e iss uesm en tioned.Link t o  a  d emonstr at ion
<d iv  id ="h ead">  <di v id=" menubar" >
  < div class="mbl i nks">
     <u l >   <l i>         <a  hre f ="#" ><di v  c las s ="mei con"> </ d iv > <span>Menu1</span>< /a >
      </ li>
       <l i>
      < a href=" #""> < di v  class="meicon "></d iv><span>M e nu2</spa n></a >
      </li>
    <li>      <ah r ef ="#"><div cla s s ="me ic on"></d iv> <span>M enu 3</ spa n>< /a >
      </li>
   < /u l> 
  </di v >
 </div > <d iv  id ="men u cont"> </div >
</ di v> 
.a ctive { -w e b kit- fi lt er:gra ys cale( 1);f ilt er: gra yscale(1) ;
} 
$(' #m en ubar ul  li').hover(f un ction() {
v arcat =$ ( this).te xt()
$('.meicon').remov e Class(' act ive') ;
$( this).fin d($ ('.mei con ' )).add Class( 'acti ve '); $('#m e n uc ont ') .html(
.find(".meicon").css("-webkit-filter","grayscale(1)");
var cat_= $(this).text();
$("#menucont").text(cat);
$("#menucont").fadeIn().css("display","block");
$("#menucont").css("left",_function(){
 return ($("body").width() -_$(this).width()) /_2;
});

//menucount_hover event
$("#menucont").hover(function(){
$("#menucont").css("display","block");
grey.find(".meicon").css("-webkit-filter","grayscale(1)");
},
function(){
$("#menucont").css("display","none");
$(".meicon").css("-webkit-filter","grayscale(0)");
});_

},
function(){
$(".meicon").css("-webkit-filter","grayscale(0)");
$("#menucont").css("display","none");
});

I_hope you understand_my problem.
Sorry for_my lame english.
Help is_very much appreciated!

A:

Revision_-_updated all the code and fixed the issues mentioned.
Link to a demonstration
<div id="head">
 <div_id="menubar">
_ _<div_class="mblinks">
_    <ul>
_    _ <li>
_       _<a_href="#"><div class="meicon"></div><span>Menu1</span></a>
 _     </li>
   _   <li>
  _  ___ <a href="#""><div class="meicon"></div><span>Menu2</span></a>
_     _</li>
     _ <li>
     _   <a href="#"><div class="meicon"></div><span>Menu3</span></a>
_    _ </li>
_    </ul>
_  </div>
_</div>
 <div_id="menucont"></div>
</div>

.active {
-webkit-filter: grayscale(1);
filter:_grayscale(1);
}

$('#menubar ul li').hover(function() {

var cat =_$(this).text()
$('.meicon').removeClass('active');
$(this).find($('.meicon')).addClass('active');

$('#menucont').html(