Menú horizontal con subpestañas hecho con CSS – Lincoln – Email

El siguiente menú es unmenú horizontal con subpestañas llamado Professional dropdown y es creado porStu nicholls. Está hecho a base de CSS y tiene un aire de elegancia y profesionalismo con la posibilidad de agregar subpestañas dentro de las subpestañas por lo que lo hace un menú de multiniveles bastante práctico.
Puedes verlo funcionando en el ejemplo de abajo.


Aunque agregarlo al blog pueda parecer complicado la verdad es que es bastante sencillo, así que empecemos y veamos cómo se hace.

ATENCIÓN: Si usas una plantilla hecha a través del Diseñador de plantillas de Blogger primero necesitas seguir los pasos de esta entrada.

Primero entramos enDiseño | Edición de HTML y antes de/b:skin pega los estilos:
#nav {
padding:0;
margin:0;
list-style:none;
height:28px;
position:relative;
z-index:500;
font-family:arial, verdana, sans-serif;
}
#nav li.top {display:block; float:left;}
#nav li a.top_link {
display:block;
float:left;
height:28px;
line-height:27px;
color:#ccc;
text-decoration:none;
font-size:11px;
font-weight:bold;
padding:0 0 0 12px;
cursor:pointer;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_l2KI0VAyYQUsQphPhyphenhyphenHwsPkdN6PrN_lO9oyDIUX7Stty8qoBn6oZqzVd-OU1c_IquVLbU7oiSLDTbYYxCWz8jbhUGYeS2xB5-l4ESrGndgpz2n08NWbwLKLzGPO7CT-NENY-63iBy5ox/);
}
#nav li a.top_link span {
float:left;
display:block;
padding:0 24px 0 12px;
height:28px;
background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_l2KI0VAyYQUsQphPhyphenhyphenHwsPkdN6PrN_lO9oyDIUX7Stty8qoBn6oZqzVd-OU1c_IquVLbU7oiSLDTbYYxCWz8jbhUGYeS2xB5-l4ESrGndgpz2n08NWbwLKLzGPO7CT-NENY-63iBy5ox/) right top;
}
#nav li a.top_link span.down {
float:left;
display:block;
padding:0 24px 0 12px;
height:28px;
background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjTYEjHSgJcZQDyVA1A5bk-0hWiLjMbd-fn5gjj9wvj80JCS-TaAU_LHTmXw1kxtKrdemq_DQjjPPQxAHiRyNGzhFQHibeSQqw5X_NkZcwqkF0zWgTJp_QbK8OsG2BlI8GTPpIHV5cxH4zW/) no-repeat right top;
}
#nav li a.top_link:hover {color:#fff; background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh63UxAjwcNLKf4l50UlSL8RHilVH6LNepx3aCLwPVZeKyWca39WsxqexjZEJIU4vq7lnU1aI3Sski0Lp4eTr_kNefiC0zZvj_qAvArpE5bVuaNyAlV9xJ0h0ZmwHWIjQalcFMmauUkRxGt/) no-repeat;}
#nav li a.top_link:hover span {background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh63UxAjwcNLKf4l50UlSL8RHilVH6LNepx3aCLwPVZeKyWca39WsxqexjZEJIU4vq7lnU1aI3Sski0Lp4eTr_kNefiC0zZvj_qAvArpE5bVuaNyAlV9xJ0h0ZmwHWIjQalcFMmauUkRxGt/) no-repeat right top;}
#nav li a.top_link:hover span.down {background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpqaWh2SlZg15EpZlkIIARqDzkjSuJACBjbcHReayYYbc5k68zkroPDelyEwHCM3ox1y3jvDXjNy7KBNjnft8hfrqNfqWV07APKidW5OadmIdAaGUSY9zt_dx-CXe65GzK75OzAtd-Xq-F/) no-repeat right top;}

#nav li:hover a.top_link {color:#fff; background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh63UxAjwcNLKf4l50UlSL8RHilVH6LNepx3aCLwPVZeKyWca39WsxqexjZEJIU4vq7lnU1aI3Sski0Lp4eTr_kNefiC0zZvj_qAvArpE5bVuaNyAlV9xJ0h0ZmwHWIjQalcFMmauUkRxGt/) no-repeat;}
#nav li:hover a.top_link span {background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh63UxAjwcNLKf4l50UlSL8RHilVH6LNepx3aCLwPVZeKyWca39WsxqexjZEJIU4vq7lnU1aI3Sski0Lp4eTr_kNefiC0zZvj_qAvArpE5bVuaNyAlV9xJ0h0ZmwHWIjQalcFMmauUkRxGt/) no-repeat right top;}
#nav li:hover a.top_link span.down {background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpqaWh2SlZg15EpZlkIIARqDzkjSuJACBjbcHReayYYbc5k68zkroPDelyEwHCM3ox1y3jvDXjNy7KBNjnft8hfrqNfqWV07APKidW5OadmIdAaGUSY9zt_dx-CXe65GzK75OzAtd-Xq-F/) no-repeat right top;}

#nav li:hover {position:relative; z-index:200;}
#nav ul,
#nav li:hover ul ul,
#nav li:hover ul li:hover ul ul,
#nav li:hover ul li:hover ul li:hover ul ul,
#nav li:hover ul li:hover ul li:hover ul li:hover ul ul
{position:absolute; left:-9999px; top:-9999px; width:0; height:0; margin:0; padding:0; list-style:none;}

#nav li:hover ul.sub{
left:0;
top:28px;
background: #fff;
padding:3px;
border:1px solid #3a93d2;
white-space:nowrap;
width:90px;
height:auto;
z-index:300;
}
#nav li:hover ul.sub li{
display:block;
height:20px;
position:relative;
float:left;
width:90px;
font-weight:normal;
}
#nav li:hover ul.sub li a{
display:block;
font-size:11px;
height:20px;
width:90px;
line-height:20px;
text-indent:5px;
color:#000;
text-decoration:none;
}
#nav li ul.sub li a.fly
{background:#fff url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhyPunfInzLpjDb64TLkxIlpOZ1hPUPThtXPdgP3LBCZZtsA5W1DIGjan2eeiO1uZn8JPjhVyO5z_h_IElkTLtO8YroGKfTtNaGULofXYIb4cCA_vNHqak96hBFAEWhN0aTPgw5GUS3pTrW/) 80px 7px no-repeat;}
#nav li:hover ul.sub li a:hover
{background:#3a93d2; color:#fff;}
#nav li:hover ul.sub li a.fly:hover
{background:#3a93d2 url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAxI_E2cNiOPRcLHCdfkRuK0L94dpPOz1EV5Qruys_rBF52F2y5H783iRDSNcmsIncQyVpBfHLwF3dAoa9725qj7YrX445WWn9qCX6ix70jRcQIuoXGb1x6hs-eWNSlpQ2LKWnInavu1jC/) 80px 7px no-repeat; color:#fff;}

#nav li:hover ul li:hover a.fly {background:#3a93d2 url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAxI_E2cNiOPRcLHCdfkRuK0L94dpPOz1EV5Qruys_rBF52F2y5H783iRDSNcmsIncQyVpBfHLwF3dAoa9725qj7YrX445WWn9qCX6ix70jRcQIuoXGb1x6hs-eWNSlpQ2LKWnInavu1jC/) 80px 7px no-repeat; color:#fff;}

#nav li:hover ul li:hover ul,
#nav li:hover ul li:hover ul li:hover ul,
#nav li:hover ul li:hover ul li:hover ul li:hover ul,
#nav li:hover ul li:hover ul li:hover ul li:hover ul li:hover ul
{left:90px; top:-4px; background: #fff; padding:3px; border:1px solid #3a93d2; white-space:nowrap; width:90px; z-index:400; height:auto;}
Ahora entra enDiseño | Elementos de la página | Añadir un gadget | HTML/Javascript y ahí pega lo siguiente:
ul id="nav"
li class="top"a href="URL del enlace" class="top_link"spanPestaña 1/span/a/li

li class="top"a href="#" class="top_link"span class="down"Pestaña 2/span/aul class="sub"lia href="#" class="fly"Pestaña 2.1/aul
lia href="URL del enlace"Pestaña 2.1.1/a/li
lia href="URL del enlace"Pestaña 2.1.2/a/li
lia href="URL del enlace"Pestaña 2.1.3/a/li
/ul
/li
li class="mid"a href="#" class="fly"Pestaña 2.2/a
ul
lia href="URL del enlace"Pestaña 2.2.1/a/li
lia href="URL del enlace"Pestaña 2.2.2/a/li
lia href="URL del enlace"Pestaña 2.2.3/a/li
lia href="#" class="fly"Pestaña 2.2.4/a
ul
lia href="URL del enlace"Pestaña 2.2.4.1/a/li
lia href="URL del enlace"Pestaña 2.2.4.2/a/li
lia href="URL del enlace"Pestaña 2.2.4.3/a/li
/ul
/li
lia href="URL del enlace"Pestaña 2.2.5/a/li
lia href="#" class="fly"Pestaña 2.2.6/a
ul
lia href="URL del enlace"Pestaña 2.2.6.1/a/li
lia href="URL del enlace"Pestaña 2.2.6.2/a/li
/ul
/li
/ul
/li
lia href="URL del enlace"Pestaña 2.3/a/li
lia href="URL del enlace"Pestaña 2.4/a/li
lia href="URL del enlace"Pestaña 2.5/a/li
/ul
/li

li class="top"a href="#" class="top_link"span class="down"Pestaña 3/span/a
ul class="sub"
lia href="URL del enlace"Pestaña 3.1/a/li
lia href="URL del enlace"Pestaña 3.2/a/li
lia href="URL del enlace"Pestaña 3.3/a/li
lia href="URL del enlace"Pestaña 3.4/a/li
/ul
/li

li class="top"a href="#" class="top_link"span class="down"Pestaña 4/span/a
ul class="sub"
lia href="URL del enlace"Pestaña 4.1/a/li
lia href="#" class="fly"Pestaña 4.2/a
ul
lia href="URL del enlace"Pestaña 4.2.1/a/li
lia href="URL del enlace"Pestaña 4.2.2/a/li
lia href="URL del enlace"Pestaña 4.2.3/a/li
lia href="URL del enlace"Pestaña 4.2.4/a/li
lia href="URL del enlace"Pestaña 4.2.5/a/li
lia href="URL del enlace"Pestaña 4.2.6/a/li
/ul
/li
lia href="URL del enlace"Pestaña 4.3/a/li
lia href="URL del enlace"Pestaña 4.4/a/li
lia href="URL del enlace"Pestaña 4.5/a/li
lia href="URL del enlace"Pestaña 4.6/a/li
/ul
/li

li class="top"a href="#" class="top_link"span class="down"Pestaña 5/span/a
ul class="sub"
lia href="URL del enlace"Pestaña 5.1/a/li
lia href="URL del enlace"Pestaña 5.2/a/li
lia href="URL del enlace"Pestaña 5.3/a/li
/ul
/li

li class="top"a href="URL del enlace" class="top_link"spanPestaña 6/span/a/li

/ul
Ya sólo agrega la URL de los enlaces y el nombre de las pestañas donde se indica.
Si quisieras agregar otra pestaña simple sólo añade antes del último /ul una línea como esta:
li class="top"a href="URL del enlace" class="top_link"spanPestaña/span/a/li
Si quisieras agregar una pestaña con subpestañas entonces agrega este código:
li class="top"a href="#" class="top_link"span class="down"Pestaña/span/a
ul class="sub"
lia href="URL del enlace"Sub pestaña/a/li
lia href="URL del enlace"Sub pestaña/a/li
lia href="URL del enlace"Sub pestaña/a/li
/ul
/li
Y si quisieras que una de las subpestañas tuviera otras subpestañas entonces elimina una línea como la que está en color verde y cámbiala por un código como este:
lia href="#" class="fly"Sub pestaña/a
ul
lia href="URL del enlace"Otra Sub pestaña/a/li
lia href="URL del enlace"Otra Sub pestaña/a/li
lia href="URL del enlace"Otra Sub pestaña/a/li
/ul
/li
Y eso es todo. Como dije antes, la instalación es sencilla pero puede parecer complicado cuando se quieren agregar las subpestañas pero una vez entendiendo la estructura del menú será pan comido.
¿Y el color de fondo? El color del menú así como de las subpestañas está hecho a base de imágenes así que quien quiera cambiarle de color tendrá que editar todas las URLs de las imágenes que se encuentran en el primer código.

Donate Car To Charity CALIFORNIA DONATE CAR FOR TAX CREDITDONATE CARS IN MADONATE YOUR CAR SACRAMENTOHOW TO DONATE A CAR IN CALIFORNIA DONATE YOUR CAR FOR KIDS,CAR INSURANCE QUOTES COLORADO ,NUNAVUT CULTURE,DAYTON FREIGHT LINESHARDDRIVE DATA RECOVERY SERVICES,DONATE A CAR IN MARYLAND,MOTOR REPLACEMENTS,CHEAP DOMAIN REGISTRATION HOSTING,DONATING A CAR IN MARYLANDNos ofrece Mundial Football eloan com, FIFA World Cupuna gran variedad para contratar mesothelioma info y obtener un equity line of credit y una buena estructura de negocio SEO consolidate loans y visitar su casa matriz Mesothelioma law firm,home equity loans domain name searchSelling annuity payments for cash,Sell my structured settlement,Sell structured settlement,Structured settlement,Structured settlement companies,Sell my annuity payments lump sum,Car accident lawyer Denver,Accident injury attorneys,Sell my annuity

Seo services mesothelioma attorney average mesothelioma settlement BETTER CONFERENCING CALLS car insurance in south dakota Donate Car To Charity CALIFORNIA NEUSON structured settlement buyer Donate a car in Maryland diagnosed with mesothelioma Car Insurance Quotes PA Donate a Car in Maryland Cheap Car Insurance in Virginia WORLD TRADE CENTER FOOTAGE personal injury law firm Online Stock Trading Virtual Data Rooms best structured settlement companies PHD on Counseling Education Donate Car to Charity California mesothelioma care Mobile casino Best Criminal Lawyers in Arizona Criminal lawyer event management security california motorcycle accident lawyer Auto Mobile Insurance Quote quotes car Online casino Php programmers Sell Annuity Payment compare life assurance car insurance quotes pa Cheap Auto Insurance in VA car donate Online Christmas cards mesothelioma law firms Social media examiner Casino orlando criminal attorney Life Insurance Co Lincoln Donate cars in ma Holland Michigan College Asbestos Lawyers motorcycle accident lawyer san diego structured settlement brokers Social media campaigns Car Insurance Quotes Motor replacements Auto Accident Attorney Business finance group cloud identity and access management donate old cars to charity Christmas cards harddrive data recovery services Custom Christmas cards FORENSICS ONLINE COURSE Donating a car in Maryland Php programmers for hire ROYALTY FREE IMAGES STOCK structured settlement buyers Italian cooking school Make money online Australia Dayton Freight Lines WEBEX COSTS domain registration yahoo CAR INSURANCE QUOTES MN Casino reviews mesotheolima ANNUITY SETTLEMENT car insurance quotes domains yahoo Dwi lawyer Car Insurance Companies DONATE A CAR IN MARYLAND Injury Lawyers Donate your car for kids DUI lawyer Live casino Criminal defense lawyer DONATING A CAR IN MARYLAND Hire php developers DAYTON FREIGHT LINES How to Donate A Car in California small business administration sba Hire php programmers injury lawyers Dallas Mesothelioma Attorneys workplace accident attorney WordPress hosting Best social media platforms Register Free Domains Donating used cars to charity accident attorney orange county DONATE YOUR CAR FOR KIDS Service business software personal injury solicitor Nunavut Culture Paperport Promotional Code att call conference car accident lawyer in san diego online criminal justice degree CHEAP DOMAIN REGISTRATION HOSTING Massage school Dallas Texas Health Records Personal Health Record donate your car for money Hire php developer Custom WordPress theme designer illinois law lemon Bankruptcy lawyer Cheap Domain Registration Hosting Computer science classes online auto accident attorney Torrance wisconsin mesothelioma attorney CAR INSURANCE QUOTES COLORADO

Share: