Monday, June 29, 2009

[jQuery] Re: clueTip with dynamic ajax parameter

After several days, I finally came upon the solution! By using the id
I already had collected I could call the cluetip function using the
dynamic id parameter instead of the .helptext class

$(document).ready(function() {
$(".helptext").each(function() {
var helptext_id = $(this).attr("id").toString();

$('#'+helptext_id).attr('rel', '../../AJAX/
GetHelpText.aspx').cluetip({
showTitle: false,
ajaxSettings: {
type: "GET",
data: "q=" + helptext_id
}
});
});

No comments: