Re: prototype.js Ajax example?

chuck clark
Mon, 25 Jul 2005 18:17:30 -0000

Hi,
  Thanks so much to everyone.  I am starting to understand the Ajax
calls a bit better.  Infact
Ajax.PeriodicalUpdater  is perfect for my application.
I wonder how i can better format the results from clitest.php .  here
is my script

ajax-text.html



<script type="text/javascript"
src="javascript/prototype.js">


window.onload=function()
{new Ajax.PeriodicalUpdater(''number'',
''clitest.php'',{asynchronous:true, evalScripts:true,
frequency:5});
return false;
}











and here is what is returned by clitest.php

<?xml version="1.0" ?>

Some Title
Blah blah some content here.
http://www.somelink.com



What I would like to do is format the header, body and link into ajax-text.html

Some Title <a
href="http://www.somelink.com">Blah blah some content
here.



Any help is appreciated,
Chuck

> >
> > On Jul 25, 2005, at 7:48 AM, Chris Roos wrote:
> >
> >
> > <a href="#" onclick="new
Ajax.Updater(''mydivhere'', ''myurlhere'',
> {asynchronous:true, evalScripts:true}); return false;">Testing
Ajax