Menu icon Foundation

Developer | Fort Worth, TX

My Posts

  • 3
    Replies
  • Deep link inside Orbit slide

    By Matt Vasquez

    Orbit

    I'm trying to add a link inside an Orbit slide and it's resulting in some weird behavior. Mainly, multiple slides are being set to active. It works if I move the links outside the slide but that defeats the purpose of what I'm trying to accomplish. Any... (continued)

    Last Reply by Rafi Benkual over 5 years ago


My Comments

Matt Vasquez commented on Matt Vasquez's post over 5 years

Here's a simple CodePen to demonstrate the functionality:

http://cdpn.io/jAzgn

Matt Vasquez commented on Allen Petersen's post over 5 years

My app uses a lot of ajax so I run into this problem quite frequently. What's most frustrating is the behavior is not consistent across plugins (in this regard, tooltips behave differently than reveal). A more mature framework would have this consistency. Hopefully Foundation will get there because I really like it.

But I digress, here's the snippet of code I use on each project for links that are inserted into the page dynamically.

  $(document).on('click', '[data-reveal-remote]', function(){
    var $src = $(this);

    $($src.data('reveal-remote')).foundation('reveal', 'open', $src.attr('href'));

    return false;
  });
<a href="{url}" data-reveal-remote="#edit-comment-modal">Edit</a>

Hope this helps!

Posts Followed

No Content

Following

    No Content

Followers

My Posts


My Comments

You commented on Matt Vasquez's post over 5 years

Here's a simple CodePen to demonstrate the functionality:

http://cdpn.io/jAzgn

You commented on Allen Petersen's post over 5 years

My app uses a lot of ajax so I run into this problem quite frequently. What's most frustrating is the behavior is not consistent across plugins (in this regard, tooltips behave differently than reveal). A more mature framework would have this consistency. Hopefully Foundation will get there because I really like it.

But I digress, here's the snippet of code I use on each project for links that are inserted into the page dynamically.

  $(document).on('click', '[data-reveal-remote]', function(){
    var $src = $(this);

    $($src.data('reveal-remote')).foundation('reveal', 'open', $src.attr('href'));

    return false;
  });
<a href="{url}" data-reveal-remote="#edit-comment-modal">Edit</a>

Hope this helps!

Posts Followed

No Content

Following

  • No Content

Followers

  • No Content