On Wed, Aug 12, 2009 at 10:21 AM, Mr Fett<[email protected]> wrote:
> As a quick reference for anyone looking for something similar:
>
> Header Script:
>
> $('#dialog').dialog({ autoOpen: false });
>
> Link Code:
>
> onclick="$('#dialog').html('Enter a Date').dialog('option', 'title',
> 'Da Da').dialog('open');"
>
I haven't tested this, so I'm not sure if I've got the syntax exactly
right, but I believe you really want something like:
<a class="helper" href="#" title='Da Da'>help <span>Enter a Date</span></a>
> in Header Script:
$('#dialog').dialog({ autoOpen: false });
$('.helper span').hide();
$('.helper').click(function()
{
var aTag = $(this);
$('#dialog').html($('span', aTag).html())
.dialog('option', 'title', aTag.title())
.dialog('open');
});
In addition to make the link code much simpler, it allows you much
more elaborate text for the body of the help message, than would be
practical stuffed into a parameter to a function in a onclick
attribute.
--
Truth,
James
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"jQuery UI" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/jquery-ui?hl=en
-~----------~----~----~----~------~----~------~--~---