Note that there are some explanatory texts on larger screens.

plurals
  1. POMultiple SimpleModals on one page
    primarykey
    data
    text
    <p>Newbie question I think, but maybe not... I am using SimpleModal for a project, and have a case where there are multiple triggers and modals on a page. </p> <p>Page is here: <a href="http://lumetta.highchairdesign.com/newsite/lumenate-portfolio/linen" rel="nofollow">http://lumetta.highchairdesign.com/newsite/lumenate-portfolio/linen</a></p> <p>Markup for the trigger is like: </p> <pre><code>&lt;a class="modalbutton" href="#item_31" title="D112 Sand" style="background-image: url(/newsite/documents/gallery_photos/59.D112-Sand.jpg);"&gt; &lt;/a&gt; </code></pre> <p>Markup for the Modal is like: </p> <pre><code>&lt;div id="#item_31" class="modal"&gt; &lt;h3&gt;D112 Sand&lt;/h3&gt; &lt;a href="javascript:;" class="lumenate_largethumb" style="background-image: url(/newsite/documents/gallery_photos/59.D112-Sand.jpg);"&gt; &lt;/a&gt; &lt;/div&gt; </code></pre> <p>Yes, I know it's odd, but the modal contains a sprite so that is why I am using an A with a background image... </p> <p>My JS looks like: </p> <pre><code>$(".modalbutton").click(function (e) { var iden = $(this).attr("href"); $("" + iden + "").modal( { close: true }); }); </code></pre> <p>My JS is trying to figure out which link has been clicked, and inject it with the proper DIV. I get the click action, I get the modal container to appear, but the content does not get injected.</p> <p>I tried quotes around the "iden" variable, I tried no quotes... doesn't help. I tried thedirect call to the modal action, which looks like $.modal( $( iden ), { etc..., no luck there. I tried passing the content div ID to the proper setting variable for SimpleModal, which is "dataId"... no dice. </p> <p>I'm losing my mind and going to bed. This was supposed to be simple. Help? </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload