Part of the EllisLab Network
   
 
Ajax.PeriodicalUpdater won’t return string (Solved)
Posted: 14 March 2008 04:52 PM   [ Ignore ]  
Summer Student
Total Posts:  12
Joined  09-17-2007

Hello and sorry if someone have asked this before, but i couldn’t find anything.

I just have a div that i want to update every 2 seconds.
I downloaded the Prototype library and included it with my app.
<\script type=“text/javascript” src=”/src/prototype.js” > // the \ is there so the code is being displayed grin
The folder “src” is in the root and has the right owner etc.

Then i do this:

new Ajax.PeriodicalUpdater('artist', '/index.php/iTunes/getArtist', {method: 'get', asynchronous:true, insertion: Element.update, frequency:2});

the /index.php/iTunes/getArtist is returning a value so its nothing wrong there.

But my div on the other hand is not updating at all.

Does anyone now what i am doing wrong?

Thanks;
- Audun

EDIT: In the SVN version of prototype the prototype.js file is missing for the dist folder. I assumed that the prototype.js in the src was the correct one. I have now downloaded the old november file and everything is working perfectly

Profile
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 819, on March 11, 2010 11:15 AM
Total Registered Members: 120493 Total Logged-in Users: 33
Total Topics: 126564 Total Anonymous Users: 3
Total Replies: 665425 Total Guests: 320
Total Posts: 791989    
Members ( View Memberlist )