views:

327

answers:

1

I am using Simple Modal, the OSX style version. I have two calls to the modal and therefore two versions of content. When either of the buttons is clicked it selects only the first lot of content.

There is nowhere to put a hook on the content like most modal windows as there is no javascript on the page to add parameters... only an external .js file which I don't want to touch for obvious reasons.

Can anyone help me with this problem?

Click here to view the page

A: 

I did the same thing on a site I'm building. I just created different content for each modal and gave each one a unique ID. So my content looked something like:

<a id='help'>HELP CONTENT</a>
<a id='about'>ABOUT CONTENT</a>
<a id='options'>OPTIONS CONTENT</a>

<div id='modal_help'>HELP CONTENT</div>
<div id='modal_about'>ABOUT CONTENT</div>
<div id='modal_options'>OPTIONS CONTENT</div>

Then in my JS, I have:

$('a').click(function (e) {
    e.preventDefault();

    $('#modal_' + this.id).modal({OPTIONS});
});

Hope that helps.

Eric Martin