2008/11/5 Alex Mcauley <[EMAIL PROTECTED]>:
> can you re-post your full sourcecode for the funciton and the elements that
> it produces and the elements you want to observe .. i will edit it for you
> and put in some debugging for you
So the javascript function (with your slight change) is:
Event.observe(window,'load',function() {
new Ajax.PeriodicalUpdater('dticketlist','data/fetchliveticketview.php',{
frequency:300,
decay:2,
onSuccess:function(e) {
$$('li.clickinc').invoke('observe','click',function(evt) {
var elm;
var id;
elm = evt.element();
id = elm.id || '(no id)';
$('dmain').update('Updated text after clicking on '+id);
})
}
});
});
The relevant part of the main HTML page is:
<div id='dticketlist'>Loading...</div>
<div id='dmain'></div>
data/fetchliveticketview.php returns something like:
<h6>Your Live Tickets</h6>
<ul>
<li id='M794751' class='clickinc'>M794751</li>
<li id='M784800' class='clickinc'>M784800</li>
<li id='M796555' class='clickinc'>M796555</li>
<li id='M791122' class='clickinc'>M791122</li>
<li id='M757562' class='clickinc'>M757562</li>
<li id='M747790' class='clickinc'>M747790</li>
</ul>
<p>at 11:58:02</p>
--
James Hoddinott
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Prototype & script.aculo.us" 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/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---