/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
$(document).ready(function () {
    $dohome=$("a.haz_inicio");
    $dofavorite=$("a.haz_favorito");
    jQuery.each(jQuery.browser, function(i, val) {
               
              if((i=="msie")){
                if(val==true){
                 $dohome.hazinicio();
                }
              }
              if((i!="msie")){
                if(val==true){
                 $dohome.hide();
                }
              }

    });
    
    $dofavorite.hazfavorito();
    $submenu=$(".menu_cont");
    $submenu.mostrar();
});
jQuery.fn.mostrar=function(){

    this.hover(
    function(){
       $('.submenu_pral').fadeIn("slow");
    },
    setTimeout(function(){
       
       $('.submenu_pral').hide();
    },100)
    );
    
}
jQuery.fn.hazinicio=function(){
    this.click(function () {
            $pagina='http://localhost/070_09_DBBMF';
            this.style.behavior="url(#default#homepage)";
            this.setHomePage($pagina);
    });
}
jQuery.fn.hazfavorito=function(){
    this.click(function () {
        jQuery.each(jQuery.browser, function(i,val) {

          if((i=="msie")){
            if(val==true){
                window.external.AddFavorite(document.URL,document.title);
            }
          }
          if((i!="msie")){
            if(val==true){
                window.sidebar.addPanel(document.title,document.URL, '');
            }
          }//if
        });
    });
}


