Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Link in navbar to open modal #2254

Closed
guillem-catala opened this issue Feb 25, 2012 · 15 comments
Closed

Link in navbar to open modal #2254

guillem-catala opened this issue Feb 25, 2012 · 15 comments

Comments

@guillem-catala
Copy link

When adding a link in top navigation bar that triggers a modal, the opening modal will not show properly.
The modal visually appears under the shadowed layer created by modal-backdrop class

Tested with Firefox 3.6.8

@portacustodis
Copy link

I have this issue, as well. Tested in Firefox 10.0.2, Safari 5.1.4, and Chrome 17.0.963.56. I have two links in the nav, both triggering a modal form. The form appears under its modal-backdrop in all three browsers.

@wjrichardson
Copy link

I'm linking to a feedback modal directly from the top nav bar and haven't noticed any issues. Tested across a variety of browsers.

It may help to attach a screenshot or a jsfiddle so we can see what the problem is.

@portacustodis
Copy link

Okay, I have the nav, two divs, and two buttons. When you click the button, the modal appears, but under the black transparent modal backdrop. See Screenshot

@guillem-catala
Copy link
Author

I noticed that this happens when the HTML of the modal is in the same navbar (after or before the triggering link). If you write the modal content outside it works

@portacustodis
Copy link

Yeah, I noticed that, too. The problem is that if I move the modal outside the nav, then on a mobile browser, the modal appears outside the viewport.

@wjrichardson
Copy link

^ That [viewport problem] is an outstanding bug with the project right now. I don't think a fix has been pushed out.

@portacustodis
Copy link

Ah, okay. Thanks.

@mdo
Copy link
Member

mdo commented Mar 12, 2012

Yes, we have an outstanding issue with modal placement on mobile. We're working on that soon I hope. For now, you should be able move it before the navbar to keep it at the top of the document instead of the bottom.

We'll punt further discussion to the other issue.

@mdo mdo closed this as completed Mar 12, 2012
@holyredbeard
Copy link

Still the same problem for me, even one year later.

@cvrebert
Copy link
Collaborator

cvrebert commented Apr 8, 2013

Modals are being overhauled in v3; should help this problem.

@Trki84
Copy link

Trki84 commented May 12, 2014

This issue still appears on the 3rd version.. is there any work around solution?

@cvrebert
Copy link
Collaborator

@Trki84 Don't put a <div class="modal"> inside the navbar. If your issue is something else, and is not covered by http://getbootstrap.com/getting-started/#support-fixed-position-keyboards , then please open a new issue with a JS Fiddle example of the problem.

@Trki84
Copy link

Trki84 commented May 12, 2014

Thanks for replying, but its the same issue as Portacustodis.

@mishras
Copy link

mishras commented Oct 14, 2014

This seems to happen whenever there is a modal-div containing div section that has position style attribute set as fixed.

@cvrebert
Copy link
Collaborator

If there is still an issue here, please file a new bug with a JS Fiddle example demonstrating the problem.

@twbs twbs locked and limited conversation to collaborators Oct 14, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants