0

In my website there are css sub menus. Problem is last two sub menus gets out from the screen.

enter image description here

How can I maintain position of this sub menus?

There are some minor css tweak & code is so lengthy so I am not posting entire code here. Here is the link of live site which has the problem www.brandstik.in

2 Answers 2

1

You need to target your last 2 or 3 menu-links to manage their sub-menu positions as:

CSS:

.main-category-nav > li:nth-last-child(1) ul.super-child, 
.main-category-nav > li:nth-last-child(2) ul.super-child, 
.main-category-nav > li:nth-last-child(3) ul.super-child {
    right: 0;
}

This will change sub-menu positions of your last 3 children links.

Sign up to request clarification or add additional context in comments.

Comments

0

try

ul.super-child:last-child, ul.super-child:nth-last-child(2) {
   right: 0px;
}

The 2 container will fit into the view now.

1 Comment

But Now it creates same problem in Left side

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.