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

Dropdown causes a link with data-method='delete' not to render a DELETE request properly on RoR #613

Closed
vahe opened this issue Jul 9, 2012 · 0 comments

Comments

@vahe
Copy link

vahe commented Jul 9, 2012

I have a link with data-method='delete' in the Dropdown menu:

<div href="#" class="medium button dropdown">
    Dropdown
    <ul>
        <li><a href="users/sign_out" data-method="delete" rel="nofollow">Logout</a></li>
    </ul>
</div>

To send a DELETE request, I'm using jquery-ujs( on Ruby on Rails ). When clicked on the link from the dropdown, a GET request is sent. On the other hand, when I move the <ul> outside the dropdown or just remove the dropdown class from the div, everything works as expected - a DELETE request is sent.
Now, I'm not sure if this is because the way foundation renders dropdowns or because of jquery-ujs, but at this point I'm pretty sure it's a bug.

@ghost ghost assigned mhayes and nneal Jul 9, 2012
hatefulcrawdad pushed a commit that referenced this issue Aug 5, 2012
Fixes issue #613: all dropdown events were prevented from bubbling up the DOM tree
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants