Newbie question regarding passing a variable to a dialog
Hi,
I'm hoping this is an easy question. I have a dialog box that I want
to pass a variable to but am not sure the right way to do it.
This is the dialog creation
// Dialog
$('#dialog').dialog({
autoOpen: false,
width: 700,
height: 500,
buttons: {
"Ok": function() {
$(this).dialog("close");
},
"Cancel": function() {
$(this).dialog("close");
}
}
});
This is the contents of the dialog...
<!-- ui-dialog -->
<div id="dialog" title="Event">
<div id="etabs">
<ul>
<li><a href="#etabs-1">Details</a></li>
<li><a href="#etabs-2">Location</a></li>
<li><a href="#etabs-3">Attendees</a></li>
<li><a href="#etabs-4">Photos</a></li>
<li><a href="#etabs-4">Comments</a></li>
</ul>
<div id="etabs-1"></div>
<div id="etabs-2"></div>
<div id="etabs-3"></div>
<div id="etabs-4"></div>
</div>
</div>
And this is how I'm accessing it.
<a onClick="$('#dialog').dialog('open')"><span class="file">Event One</
span></a>
Basically what I need to be able to do is to pass an eventId through
the link so the dialog opens up with the information for that event.
Any help would be most appreciated.
Thanks,
Hez