• Gear
  • Shots
  • Photo Craft
  • Video
  • Wide Angle
  • Support
  • New Stuff
  • More
Support SmugMug Customization Dropdown Navbar help thread

FAQtoid

Ever wanted to create an Avatar? Creating an Avatar!

Searching Dgrin with Google Searching with Google

Dgrin Challenges

Congratulations to the Winner of DSS #128 (Sunrise or Sunset), ShootingStar.

The next Dgrin Challenge DSS #129 (Silhouette Revisited ) is open for entries through May 27th, 2013 at 8:00pm PDT.

As always, we look forward to your participation but please do take a moment to read through the rules before posting your entry.

Past DSS Challenge Winners, DSS Challenge Rules, and other important DSS Challenge information is here.

Need some help with Accessories?

Tutorials

Ever find yourself wondering just how someone managed to create an image using different effects?

Here are three simple tutorials we hope will encourage you to try something new.

The Hot Seat

A lifelong interest in landscape photography has led Eyal Oren to make a study of his adopted hometown of Marblehead, MA. As you can see, his dedication is paying off!

Africa!

Dgrinners Harryb, Pathfinder, and others joined Andy Williams and Marc Muench on Safari in East Africa recently. Here are some awesome threads to check out!

 
Thread Tools Display Modes
Page 110  of  125
Old Sep-13-2012, 10:42 AM
#2181
chandswu is offline chandswu
Beginner grinner
Quote:
Originally Posted by chandswu View Post
I'm guessing this has already been covered somewhere, but I can't find it. I added the drop down navbar code for my site and the menus are working great. Except. When the drop down hits a photo or other element on the page, the menu is pushed behind the other element. i.e. you can't see the parts of the menu that are in the same place as the photo. You can see it here: http://www.bradkehrphotography.com/ with the Portfolio tab. There should be three more drop down elements in that menu. How do I get them be seen? Thanks. (I've seen this happen on Chrome and IE Explorer. I don't know about Firefox and Safari.)
Nevermind, I think I got it. Had to do with z-index values on the slideshow overriding the navbar.
Old Sep-16-2012, 01:07 PM
#2182
Couldbe is offline Couldbe
Central Florida
Centering Drop Down Nav
Having some trouble with centering the nav bar. Just started working with this drop down nav bar.
Any info on how to center would be great. I have tried several things, but no luck.

Mike
__________________
Regards,
Mike
http://mddowns.smugmug.com/
Old Sep-16-2012, 02:20 PM
#2183
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by Couldbe View Post
Having some trouble with centering the nav bar. Just started working with this drop down nav bar.
Any info on how to center would be great. I have tried several things, but no luck.

Mike
The auto R/L margin centers the width, 200 is close for now until you add more buttons.
Code:
      /* style the outer div to give it width */
.menu {
   z-index:99;
   position:relative;    /* Make the container moveable */
   margin: 0 auto 20px;  /* top R/L bottom */
   width:200px;          /* Main bar total width, minimize to not wrap to two lines*/
}

Last edited by Allen; Sep-16-2012 at 02:30 PM.
Old Sep-16-2012, 03:16 PM
#2184
Couldbe is offline Couldbe
Central Florida
That's it Thanks!
Quote:
Originally Posted by Allen View Post
The auto R/L margin centers the width, 200 is close for now until you add more buttons.
Code:
      /* style the outer div to give it width */
.menu {
   z-index:99;
   position:relative;    /* Make the container moveable */
   margin: 0 auto 20px;  /* top R/L bottom */
   width:200px;          /* Main bar total width, minimize to not wrap to two lines*/
}
Will adjust accordingly as I add more buttons. . Thanks for your help. You make it look so easy!!
Mike
__________________
Regards,
Mike
http://mddowns.smugmug.com/
Old Sep-18-2012, 06:40 PM
#2185
Paris is offline Paris
Designer Photographer
Adding new Category Headings...
Hello,
I tried to add two additional category headings and they appeared on two staggered lines below the original menu.
Can someone please show me how to adjust my settings to allow them to be on the same line as the others.

Design Note: I am fine with raising the logo (can make it smaller) so the menu categories run under the logo.
__________________
Thanks,
Richard.
http://www.richardparisphotography.ca/
Old Sep-18-2012, 08:30 PM
#2186
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by Paris View Post
Hello,
I tried to add two additional category headings and they appeared on two staggered lines below the original menu.
Can someone please show me how to adjust my settings to allow them to be on the same line as the others.

Design Note: I am fine with raising the logo (can make it smaller) so the menu categories run under the logo.
See if this fixes it.

Replace your whole header with this. Fixes a bunch of errors.
Code:
<div id="my_banner"></div>
<div class="menu">
<ul>
<li><a href="/" title="">HOME</a></li>
<li><a href="/NEW-UNTITLED-PROJECT/21027034_GXm3x">PORTRAIT PROJECT</a></li>
<li><a href="/PORTRAITS/14638527_Qmgpv3">STUDIO PORTRAITS</a></li>
<li><a href="/INTERESTINGPEOPLE/15182219_MPdDdJ">INTERESTING PEOPLE</a></li>
<li><a href="/LANDSCAPE/15313653_d8bRMC">PLACES</a></li>
<li><a href="/OUTSIDE THE BOX/21163068_r4Rhs9">OUTSIDE THE BOX</a></li>
<li><a href="/gallery/15352911_xiEMU">CONTACT ME</a></li>
</ul>
</div>  <!-- closes menu -->
<!-- End Navbar Code -->
<div style="clear: both;"></div>
Change the red in your CSS
Code:
      /* style the outer div to give it width */
.menu {
   left:  150px;
   top:  -10px;
   z-index:99;
   margin: 0 auto 20px;  /* top R/L bottom */
   position:relative;    /* Make the container moveable */
   width: 900px;          /* Main bar total width, minimize to center */
}
Old Sep-19-2012, 05:46 PM
#2187
Paris is offline Paris
Designer Photographer
Quote:
Originally Posted by Allen View Post
See if this fixes it.

Replace your whole header with this. Fixes a bunch of errors.
Code:
<div id="my_banner"></div>
<div class="menu">
<ul>
<li><a href="/" title="">HOME</a></li>
<li><a href="/NEW-UNTITLED-PROJECT/21027034_GXm3x">PORTRAIT PROJECT</a></li>
<li><a href="/PORTRAITS/14638527_Qmgpv3">STUDIO PORTRAITS</a></li>
<li><a href="/INTERESTINGPEOPLE/15182219_MPdDdJ">INTERESTING PEOPLE</a></li>
<li><a href="/LANDSCAPE/15313653_d8bRMC">PLACES</a></li>
<li><a href="/OUTSIDE THE BOX/21163068_r4Rhs9">OUTSIDE THE BOX</a></li>
<li><a href="/gallery/15352911_xiEMU">CONTACT ME</a></li>
</ul>
</div>  <!-- closes menu -->
<!-- End Navbar Code -->
<div style="clear: both;"></div>
Change the red in your CSS
Code:
      /* style the outer div to give it width */
.menu {
   left:  150px;
   top:  -10px;
   z-index:99;
   margin: 0 auto 20px;  /* top R/L bottom */
   position:relative;    /* Make the container moveable */
   width: 900px;          /* Main bar total width, minimize to center */
}
Fixed and great - thanks!
__________________
Thanks,
Richard.
http://www.richardparisphotography.ca/
Old Sep-21-2012, 08:23 AM
#2188
GrahamGarner is offline GrahamGarner
Big grins
Having trouble can you help?
Dear Allen or anyone,

After a whole day I can't see where I'm going wrong. I've deleted and started twice, still no joy.

I think there is a bit of code I need for the drops and eventually the flyouts to go over the bio slideshow and go underneath each other.
Also, where on earth do I change the code to center the navbar?

I'm @ www.grahamgarner.co

Manythanks

G
Old Sep-23-2012, 05:34 PM
#2189
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by GrahamGarner View Post
Dear Allen or anyone,

After a whole day I can't see where I'm going wrong. I've deleted and started twice, still no joy.

I think there is a bit of code I need for the drops and eventually the flyouts to go over the bio slideshow and go underneath each other.
Also, where on earth do I change the code to center the navbar?

I'm @ www.grahamgarner.co

Manythanks

G
Add the missing closing } and if it all works.
Code:
.menu a:hover, .menu :hover > a {
  color:white;
  background:black;
}
     /* a hack so that IE5.5 faulty box model is corrected */
Old Sep-26-2012, 03:36 AM
#2190
GrahamGarner is offline GrahamGarner
Big grins
Working but can't tweek for safari and firefox
Hi Allen

Many thanks for putting me right.

I'm not sure what I'm doing wrong in the this part of the code? It works in IE, when the cursor lands on the 3rd tier and goes pink but, for Firefox and safari I think it's defaulting to black?

This is the code in level 3
}

.menu ul ul ul li a {color:gray;}
.menu ul ul ul li a:hover {color:black;}

/* style the third level background */
.menu ul ul ul a, .menu ul ul ul a:visited {background:yellow;} /* not FF */

/* style the third level hover */
.menu ul ul ul a:hover {background:red;}
.menu ul ul ul :hover > a {background:pink;} /* 3rd (w/o 4th) 4th hover */

/* style the third level links */
.menu ul ul ul a, .menu ul ul ul a:visited {
color:gray; /* hover 2nd > 3rd & 4th */
background:black; /* hover 3rd > 4th */
height:20px;
line-height:20px;
width:150px;
}

Also, (if possible) is there a bit of code to make the wording in level 2 justify left in line with the nav wording? the boxes are fine.
ie the nav line
Exhibitions and Commissions
Exhibitions (the 2nd tier)

I hope you have time to have a look, thank you for your time so far

G

Last edited by GrahamGarner; Sep-26-2012 at 04:44 AM. Reason: Add my link www.grahamgarner.co
Old Sep-26-2012, 05:02 AM
#2191
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by GrahamGarner View Post
Hi Allen

Many thanks for putting me right.

I'm not sure what I'm doing wrong in the this part of the code? It works in IE, when the cursor lands on the 3rd tier and goes pink but, for Firefox and safari I think it's defaulting to black?

This is the code in level 3
}

.menu ul ul ul li a {color:gray;}
.menu ul ul ul li a:hover {color:black;}

/* style the third level background */
.menu ul ul ul a, .menu ul ul ul a:visited {background:yellow;} /* not FF */

/* style the third level hover */
.menu ul ul ul a:hover {background:red;}
.menu ul ul ul :hover > a {background:pink;} /* 3rd (w/o 4th) 4th hover */

/* style the third level links */
.menu ul ul ul a, .menu ul ul ul a:visited {
color:gray; /* hover 2nd > 3rd & 4th */
background:black; /* hover 3rd > 4th */
height:20px;
line-height:20px;
width:150px;
}

Also, (if possible) is there a bit of code to make the wording in level 2 justify left in line with the nav wording? the boxes are fine.
ie the nav line
Exhibitions and Commissions
Exhibitions (the 2nd tier)

I hope you have time to have a look, thank you for your time so far

G
Try these changes and we'll go from there. BTW, the main width needs to be increased so it doesn't
wrap to two lines.
Code:
.menu {
  z-index:99;
  position:relative;    /* Make the container moveable */
  margin: 0 auto 20px;  /* top R/L bottom */
  width:1050px;          /* Main bar total width, minimize to not wrap to two lines*/
}

      /* style the second level links */
.menu ul ul a, .menu ul ul a:visited {
   color:white;
   background:black;
   height:20px; 
   line-height:20px; 
   width:150px;
   text-align:left;
}

      /* position the third level flyout menu */
.menu ul ul ul {
   left:170px; 
   top:0;
   width:150px;
   height:auto;
}

.menu ul ul ul li a {color:white;}
.menu ul ul ul li a:hover {color:white}

      /* style the third level background */
.menu ul ul ul a, .menu ul ul ul a:visited {background:black;}  /* not FF */

      /* style the third level hover */
.menu ul ul ul a:hover {background:gray;}
.menu ul ul ul :hover > a {background:gray;}     /* 3rd (w/o 4th) 4th hover */
Old Sep-27-2012, 03:42 AM
#2192
GrahamGarner is offline GrahamGarner
Big grins
I've put in the revised code, colour still different on formats
Quote:
Originally Posted by Allen View Post
Try these changes and we'll go from there. BTW, the main width needs to be increased so it doesn't
wrap to two lines.
Code:
.menu {
  z-index:99;
  position:relative;    /* Make the container moveable */
  margin: 0 auto 20px;  /* top R/L bottom */
  width:1050px;          /* Main bar total width, minimize to not wrap to two lines*/
}

      /* style the second level links */
.menu ul ul a, .menu ul ul a:visited {
   color:white;
   background:black;
   height:20px; 
   line-height:20px; 
   width:150px;
   text-align:left;
}

      /* position the third level flyout menu */
.menu ul ul ul {
   left:170px; 
   top:0;
   width:150px;
   height:auto;
}

.menu ul ul ul li a {color:white;}
.menu ul ul ul li a:hover {color:white}

      /* style the third level background */
.menu ul ul ul a, .menu ul ul ul a:visited {background:black;}  /* not FF */

      /* style the third level hover */
.menu ul ul ul a:hover {background:gray;}
.menu ul ul ul :hover > a {background:gray;}     /* 3rd (w/o 4th) 4th hover */
Hi Allen

Many thanks for the code.

What I would like the colors to be when you
hover on Exhibitions the 3rd level will appear Background Black and Wording colour grey
When you hover on the 3rd tier ie Blackall Studios background goes grey and the wording black.

At present Safari is

background black wording grey (which is fine) on the 3rd tier Black, white

On Firefox & IE

Black, white then grey, white

Any ideas?

Lastly, is there a part of your code some where which changes the width of the drop boxes? I want them to be the same size but, as large as the longest word plus a little padding on the right the same as now on the left.

I hope this makes sense?

Many thanks
__________________
Graham Garner
www.grahamgarner.co
Old Sep-27-2012, 06:49 AM
#2193
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by GrahamGarner View Post
Hi Allen

Many thanks for the code.

What I would like the colors to be when you
hover on Exhibitions the 3rd level will appear Background Black and Wording colour grey
When you hover on the 3rd tier ie Blackall Studios background goes grey and the wording black.

At present Safari is

background black wording grey (which is fine) on the 3rd tier Black, white

On Firefox & IE

Black, white then grey, white

Any ideas?

Lastly, is there a part of your code some where which changes the width of the drop boxes? I want them to be the same size but, as large as the longest word plus a little padding on the right the same as now on the left.

I hope this makes sense?

Many thanks
This will give visitors the slight indication of main button hover.
Code:
.menu a:hover, .menu :hover > a {
  color:#888;
  background:white;
}
This will set the width of the drop boxes. Keep each the same. In the 2nd rule below if you change the height to "auto" the text will wrap to two lines if the width is too small for its text. All the drops will be the width set here. The longest word/name is under the Client Galleries drop.
Code:
      /* hide the sub levels and give them a position absolute so that they take up no room */
.menu ul ul {
   visibility:hidden;
   position:absolute;
   height:0;
   top:20px;       /* move drop vertically */
   left:0;         /* move drop horizontally   */
   width:150px;    /* Size of the daughter cells */
}

      /* style the second level links */
.menu ul ul a, .menu ul ul a:visited {
   color:white;
   background:black;
   height:20px; 
   line-height:20px; 
   width:150px;
   text-align:left;
}
If you want the drops for the different mains to be a different widths, that can be done but would
require adding class names to the <ul> in the html so the CSS could format each.

When adjusting the drop width the next level has to be moved over to touch the new drop width.
Code:
      /* position the third level flyout menu */
.menu ul ul ul {
   left:170px; 
   top:0;
   width:150px;
   height:auto;
}
Clean up about page. Add to CSS
Code:
.gallery_24557930 .slideshowButton,
.gallery_24557930 #albumNav_bottom,
.gallery_24557930 #albumNav_top {display:none;}
Old Sep-28-2012, 04:15 AM
#2194
twors is offline twors
Big grins
I think I have some extra Stuff!!!
Allen,
I have tried multiple suggestions from the posts above to center the new drop down nav bar (trying to tweak it to the center and up and to make it quit hiding behind the photos). I think I have some extra code in there preventing me from achieving my goal.... I almost got it.
Is there a way to embed it into my banner? What I really want to do is replace the bottom portion of my banner with the navigation bar (the engagements-weddings-blablabla portion) with something functional.

Here is the site... http://www.garrywilliamsphotography.com/
Old Sep-28-2012, 05:34 AM
#2195
GrahamGarner is offline GrahamGarner
Big grins
Many thanks Allen
Quote:
Originally Posted by Allen View Post
This will give visitors the slight indication of main button hover.
Code:
.menu a:hover, .menu :hover > a {
  color:#888;
  background:white;
}
This will set the width of the drop boxes. Keep each the same. In the 2nd rule below if you change the height to "auto" the text will wrap to two lines if the width is too small for its text. All the drops will be the width set here. The longest word/name is under the Client Galleries drop.
Code:
      /* hide the sub levels and give them a position absolute so that they take up no room */
.menu ul ul {
   visibility:hidden;
   position:absolute;
   height:0;
   top:20px;       /* move drop vertically */
   left:0;         /* move drop horizontally   */
   width:150px;    /* Size of the daughter cells */
}

      /* style the second level links */
.menu ul ul a, .menu ul ul a:visited {
   color:white;
   background:black;
   height:20px; 
   line-height:20px; 
   width:150px;
   text-align:left;
}
If you want the drops for the different mains to be a different widths, that can be done but would
require adding class names to the <ul> in the html so the CSS could format each.

When adjusting the drop width the next level has to be moved over to touch the new drop width.
Code:
      /* position the third level flyout menu */
.menu ul ul ul {
   left:170px; 
   top:0;
   width:150px;
   height:auto;
}
Clean up about page. Add to CSS
Code:
.gallery_24557930 .slideshowButton,
.gallery_24557930 #albumNav_bottom,
.gallery_24557930 #albumNav_top {display:none;}

Many thanks Allen it appears to be playing ball
__________________
Graham Garner
www.grahamgarner.co
Old Sep-28-2012, 06:45 AM
#2196
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
Originally Posted by twors View Post
Allen,
I have tried multiple suggestions from the posts above to center the new drop down nav bar (trying to tweak it to the center and up and to make it quit hiding behind the photos). I think I have some extra code in there preventing me from achieving my goal.... I almost got it.
Is there a way to embed it into my banner? What I really want to do is replace the bottom portion of my banner with the navigation bar (the engagements-weddings-blablabla portion) with something functional.

Here is the site... http://www.garrywilliamsphotography.com/
Fix the CSS comment tags and the menu will center. Then come back and ask the questions about what you still want.

Code:
/************........***************************/

/* CSS Dropdown Nav Bar */
/* Original code by Stu Nicholls of */
Old Sep-28-2012, 10:47 AM
#2197
twors is offline twors
Big grins
Quote:
Originally Posted by Allen View Post
Fix the CSS comment tags and the menu will center. Then come back and ask the questions about what you still want.

Code:
/************........***************************/

/* CSS Dropdown Nav Bar */
/* Original code by Stu Nicholls of */



4+ hours... for a slash..... Thank You, you are a true hero!

To continue...
1. Is there a way to embed my Navbar into my banner? I want to replace the bottom portion of my banner with the navigation bar (the engagements-weddings-blablabla portion out--navbar in.... ((I have already removed the blablabla... in a new banner located here; http://www.garrywilliamsphotography....-46K74Bj-L.png)) I Ultimately I would like to be able to move the banner and Nav bar as a unit should I decide it is necessary.

2. I would like to do a cleanup of all my code. I plan to migrate the current slide show to jfriends stretchy slideshow and load a splash image and want to start with just what I need in case that goes south. Could you please look it over and tell me what code is not needed and can be removed?

3. Lastly. and honestly I haven't done any searches yet, but I need to put some documents in the "INFO" nav drop downs-- Artist statement- artist bio and guarantee. Is it possible to put word or pdf documents on my site. I dont remember seeing any on others' sites.

Thanks again!!!
Old Oct-01-2012, 08:37 PM
#2198
twors is offline twors
Big grins
IE7/8/9 issues with nav bar and continuation of assistance
Quote:
To continue...
1. Some people using IE7 or IE8 are having difficulties navigating to the northern lights and below under "galleries", and pets and below under "Clients". The menu disappears, did I miss a fix for this? Firefox and safari seem to work fine.

...

Thanks again!!!

Allen- Anybody???

Last edited by Allen; Oct-02-2012 at 07:19 AM.
Old Oct-02-2012, 07:20 AM
#2199
Allen is offline Allen OP
"tweak 'til it squeaks"
Allen's Avatar
Quote:
To continue...
1. Some people using IE7 or IE8 are having difficulties navigating to the northern lights and below under "galleries", and pets and below under "Clients". The menu disappears, did I miss a fix for this? Firefox and safari seem to work fine.

...

Thanks again!!!
Quote:
Originally Posted by twors View Post
Allen- Anybody???
This might be the problem as with no .menu background the mouse is sometimes lost when slid down.

Some browsers do not like a background set to "none". Go down through the .menu CSS and change
all the backgrounds to this. It applies a very transparent background that's not visible.

background: rgba(255, 255, 255, .0001);
Old Oct-02-2012, 11:45 AM
#2200
twors is offline twors
Big grins
Quote:
Originally Posted by Allen View Post
This might be the problem as with no .menu background the mouse is sometimes lost when slid down.

Some browsers do not like a background set to "none". Go down through the .menu CSS and change
all the backgrounds to this. It applies a very transparent background that's not visible.

background: rgba(255, 255, 255, .0001);

Thanks Allen I will give that a try.
Page 110  of  125
Tell The World!  
Tags
customizatation , navbar
Similar Threads Thread Starter Forum Replies Last Post
DropDown NavBar Positioning and Color CerebrusX SmugMug Customization 6 Aug-08-2012 09:42 AM
Please Help About Dropdown Navbar wangyunpeng SmugMug Customization 2 Jul-09-2011 10:51 AM
single dropdown navbar? dogwood SmugMug Customization 33 Jun-21-2010 08:57 PM
Dropdown Navbar juan14888 SmugMug Customization 7 Apr-19-2010 05:34 PM
navbar dropdown code errors? amyparsons SmugMug Customization 20 Jan-09-2009 07:53 AM


Thread Tools
Display Modes

Posting Rules  
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump