olefredrik / FoundationPress

FoundationPress is a WordPress starter theme based on Foundation 6 by Zurb
https://foundationpress.olefredrik.com
MIT License
2.71k stars 871 forks source link

Problem in offcanvas foundation press menu #130

Closed di3gof3rn4ndes closed 9 years ago

di3gof3rn4ndes commented 9 years ago

Hello! I'm having problem in offcanvas foundation press menu, does not work when you click the menu item, not going anywhere and could not find the error site:http://www.maispiscinas.com.br offcanvas

Thanks!!!

olefredrik commented 9 years ago

Hey. This was odd. Could this be due to a conflict with a third party plugin? As you can see, this works great on the demo site must: http://foundationpress.olefredrik.com

di3gof3rn4ndes commented 9 years ago

Thanks, will check if it's some conflict with javascript or jquery , disable the plugins can solve ?

tirnovanuaurel commented 9 years ago

No issue here after clean install, although happened that some plugins to break it.

theodorocaliari commented 9 years ago

PT-BR: Hey @di3gof3rn4ndes, acredito que a div (exit-off-canvas) não deve estar fechada corretamente, ela esta envolvendo o menu também.... por este motivo ao clicar no item do menu ele o esconde... tente dar uma olhada na documentação do próprio Foundation para entender como é a estrutura do menu - http://foundation.zurb.com/docs/components/offcanvas.html

EN: I belive that div (exit-off-canvas) doesn't has closed correctly, this div is envolving the menu div together... because of this when we click in menu item the menu is hidden again... please take a look in Foundation docs to understand the structure of the menu - http://foundation.zurb.com/docs/components/offcanvas.html

joshtipton28 commented 9 years ago

I have ran into this problem a couple times and could be related to third party plugins. Try adding an extra

to the top of your footer.php and see if it works after that.

AdamChlan commented 9 years ago

It looks like you've got it working now, possibly by adding a some JS? Looking at your code, I think the following line:

<a class="left-off-canvas-toggle menu-icon"><span></span></a>

Should be..

<a class="left-off-canvas-toggle menu-icon" href="#"><span></span></a>

You need the href in there.

cshenry13 commented 9 years ago

It worked for me adding a div here, in footer.php:

<a class="exit-off-canvas"></a>
</div>
darkblk commented 9 years ago

I found a solution to this today after reading through the Foundation docs for Off-Canvas. You need to reflow after document load:

$(document).foundation('offcanvas', 'reflow'); http://foundation.zurb.com/docs/components/offcanvas.html

Must be something to do with how the menus are built into the page? Anyway, happy days now its fixed :dancer: