Jump to content

Archived

This topic is now archived and is closed to further replies.

Jinfiltration

need to center the menu and the drop downbox

Recommended Posts

Jinfiltration    2
Jinfiltration

Hi,

 

I need to center the words in the menu bar and the dropdown box, may i know where should i edit in CSS?

 

i did some edit on the css file, i finally moved the dropdown box to almost center, but i couldnt move the word in the menu to the center.

 

h3EumyB.jpg

Share this post


Link to post
Share on other sites
Jake    74
Jake

Hi Jinfiltration - Is that the navbar you're using for your menu? If so, try adding the following to center the dropdown items:

 

body .dropdown-menu li > a, body .dropdown-menu li > span {text-align: center;}


Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites
Jinfiltration    2
Jinfiltration

Hi Jinfiltration - Is that the navbar you're using for your menu? If so, try adding the following to center the dropdown items:

 

body .dropdown-menu li > a, body .dropdown-menu li > span {text-align: center;}

 

sorry, i dont get it, i just started learning css, may i know from the code below where should i edit or add to make all the words in the bar and the dropdown box to be center.

/* @ Main Nav */
		.main_nav {			
			line-height: 1.1em;
			text-align: left;
			margin-top: 0px;
			z-index:28;  /* Fancybox Uses 30 */
			position:relative;
		}
		
		.main_nav .content-pad{
			padding-top: 6px;
		}
			.main_nav ul{
				list-style: none;
				display: block;
				margin: 0px 0px 0px 180px;
				padding: 0px;
				float: left;
			}
			.main_nav li{position:relative;}
			.main_nav ul li{
				margin: 0px 0px 0px 20px;
				padding: 0px;
				float: left;
				text-align: right;
			}
			.main_nav li a{		
				
				padding: 10px 15px 10px;
				text-decoration: none;
				display: block;
				border: 1px solid transparent;
				border-bottom:none;
					
			}
			
			.main-nav li a{
				font-size: 1.2em; 
			}
			
			/*IE6 border color (transparent border fix)*/
			*html .main_nav li a{ border-color: white; }
	
			/* Drop Down */
			.main_nav ul ul {display: none;}
			.main_nav ul ul li {text-align: left;}
		
			/* @ SubNav Area */
			#secondnav {
				line-height: 1.1;
				font-size: .7em; 
			}
				#secondnav ul{
					line-height: .95em;
					list-style:none;
					margin:0;
					
				}
				#secondnav .secondnav_menu { margin:0 0 0 0px; }
				#secondnav ul li{float: left;}
				#secondnav li a{
					display: block;
					padding: 10px 10px; 
					border:none;
				}

Share this post


Link to post
Share on other sites
Jake    74
Jake
Hi Jinfiltration - I think you've posted in the wrong forum so I'm sorry for the confusion with the code I provided. But looking at your code, I'd advise you try tweaking the following under /* Drop Down */ where it currently says "left": .main_nav ul ul li {text-align: center;} If that doesn't do the trick, could you provide a link to the site?

Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites
Jinfiltration    2
Jinfiltration

Hi Jinfiltration - I think you've posted in the wrong forum so I'm sorry for the confusion with the code I provided. But looking at your code, I'd advise you try tweaking the following under /* Drop Down */ where it currently says "left": .main_nav ul ul li {text-align: center;} If that doesn't do the trick, could you provide a link to the site?

 

yes, sure. my website is http://69.195.124.132/~myownlo1/

Share this post


Link to post
Share on other sites
Jake    74
Jake
Hi Jinfiltration - Thanks for the link. I believe the code I provided should do the trick with centering the text in the dropdown menu. .main_nav ul ul li {text-align: center;}

Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites
Jinfiltration    2
Jinfiltration

Hi Jinfiltration - Is that the navbar you're using for your menu? If so, try adding the following to center the dropdown items:

 

body .dropdown-menu li > a, body .dropdown-menu li > span {text-align: center;}

 

Sorry 1 more question,

 

5YjFoTN.png

Share this post


Link to post
Share on other sites
Jake    74
Jake
Try adding this custom code to move the menu over a bit: #primary-nav ul.main-nav {margin-left: 225px;}
  • Like 1

Have you searched the forums yet or checked out the DMS user docs?

PageLines geek, blogging at MyUntangledLife.com

Share this post


Link to post
Share on other sites

  • Similar Content

    • khat
      By khat+
      I think I may have installed pagelines pro incorrectly, and then used features incorrectly. I installed first platforms framework theme and then the child, thinking I could do setup for child later. I tried to set up a background image, and tried custom css feature in pagelines dashboard. I had mistakes in my css, and just thought that if I deleted the info in the css custom feature in pagelines dashboard that the new information would overwrite the old info. The background image didn't respond at all, probably because I didn't have the child directory renamed. I then tried to use the LSS plugin to create css and added more css, possibly, somewhere -sigh-. I never did change the background image and get it placed properly. I used a workaround and in nested containers I placed a background image which worked well enough, so I moved on to try to create my nav bar/ menu bar. When I go to the Menus panel, there is NO area where I can place a menu on a page. I have read and reread and re- re- reread the instructions for placing a menu. I've used the pagelines editor to place a menu, however only HOME shows up. I've been at this for many hours. I've since uninstalled all of my pagelines items and reinstalled, thinking that it would restore all my changes to default, but no, it is still all there, with all my unresolved issues. I am completely at a loss as to what to do next.
    • bnapoli
      By bnapoli+
      http://731.34b.myftpupload.com/ this website is using the NavPro navigation in Platform 5. It has a lot of menu items, so it breaks to two lines when the window is sized down. What is the media query to make the navigation either a) switch to "mobile mode" at a higher width, or b ) expand the nav into two lines. Thanks
    • Jarek
      By Jarek+
      How to make the Impulse menu sticky?
      Here is a site that seems like it is doing just that: http://www.manhattanperiodontist.com/
      Here is the site I am working on: http://boeriu.digitalvector.com/ 
      I have no problem showing the menu at the bottom, but when scrolling up it does not stick.  I tried to add Nav Pro menu but when I do that, it just shows on top and no matter what I try is not working as I want it to.
      Any suggestions?
    • Dave
      By Dave+
      1) Toggle menu on mobile devices does not work properly, combination Chrome 56.0.2924.87 with Android 6.0.1

      2) Mobile / Default Menu > Set the primary/default navigation for your site. This will be used in the pop out mobile menu and as the default in navigation sections. Does not work.
    • flourishdesignstudio
      By flourishdesignstudio
      Hello,
      I have an older site that was built using PageLines several years ago (prior to the release of DMS). I wanted to leverage some of the power of your new PL5 plugin but the theme prevents be from adding any generated custom sidebars to the theme (through the drag and drop interface) and does not allow me to add any PL5 sections/containers/etc to the header or footer. Is there any way to easily override that or am I stuck only using PL5 in the content areas of the site?
      Thanks so much for the help!
×