To stop the stacking just use asynchronous flag and set it to false...

Though it does go against the AJAX it will work...

Perhaps you can get around the decay/frequency with somehting else

Alex Mcauley
http://www.thevacancymarket.com
  ----- Original Message ----- 
  From: William Taylor 
  To: prototype-scriptaculous@googlegroups.com 
  Sent: Tuesday, November 10, 2009 2:48 PM
  Subject: [Proto-Scripty] Re: PeriodicalExecuter that doesn't stack


This will call a function and not a url ?  new 
Ajax.PeriodicalUpdater(container, url[, options])stacking: ie multiple request 
will stack on top of each other whether or not the previous one
  has completed or not.
  If this is making a request say every second there is the possibility that 
the request may not finish in time before the
  next one gets fired off. I need a way to prevent that.


  Im using PeriodicalUpdater not PeriodicalExecutor.  I need the frequency and 
decay that Updater provides.


  Thanks,
   William




  On Nov 10, 2009, at 6:17 AM, Alex McAuley wrote:



    You have answered your own question...

    In your original post you said that you could fix the problem if you could 
    get Periodical to "call a function instead of a url" .. and what i 
suggested 
    does just that ...

    I am not sure i understand what you mean by stacking

    As for frequency: you dont need to worry about it if you are usig 
periodical 
    executor and opposed to updater

    Alex Mcauley
    http://www.thevacancymarket.com


    ----- Original Message ----- 
    From: "William Taylor" <willi...@rebelfactions.com>
    To: <prototype-scriptaculous@googlegroups.com>
    Sent: Tuesday, November 10, 2009 2:06 PM
    Subject: [Proto-Scripty] Re: PeriodicalExecuter that doesn't stack





      wow I must have been tired when I wrote that.

      I said PeriodicalExecuter but I really meant Ajax.PeriodicalUpdater



      So ya is there a way to make Ajax.PeriodicalUpdater not stack and to

      possibly give it

      a maximum frequency limit?



      -William



      On Nov 10, 2009, at 4:00 AM, Alex McAuley wrote:





        I wasn't aware that PeriodicalExecuter did call a URL...



        Ajax.PeriodicalUpdater does...





        If you want to just call a request every X seconds and change things

        just

        use PeriodicalExecutor or simply setTimeout



        Alex Mcauley

        http://www.thevacancymarket.com

        ----- Original Message -----

        From: "williamt" <willi...@rebelfactions.com>

        To: "Prototype & script.aculo.us" 

        <prototype-scriptaculous@googlegroups.com



        Sent: Tuesday, November 10, 2009 7:55 AM

        Subject: [Proto-Scripty] PeriodicalExecuter that doesn't stack







          Im looking for a way to make PeriodicalExecuter not stack plus add in

          a max period setting.



          If PeriodicalExecuter could call a function instead of a url I could

          set/clear some flags

          so it would or wouldn't make the call depending on the flags.

          But I don't see how I could do that unless I could make it call a

          function and not a url.



          I think a max period would have to be hacked into prototype. I'm not

          sure on that one though.



          Anyone have any thoughts on how I could achieve this?

          Basically PeriodicalExecuter that doesn't stack plus a max period

          setting.



          Thanks,

          William




























  

--~--~---------~--~----~------------~-------~--~----~
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 prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to