mootools Ajax fade in fade out response problem

Discussion in 'Javascript' started by Piotr Kaleta, Apr 21, 2008.

  1. Piotr Kaleta

    Piotr Kaleta Guest

    Hi I tried to load asynch. request in that order :

    fade in div,
    put response into div,
    fade out div

    problem is i get that order :

    response goes into div,
    fade in div,
    fade out div

    what is the problem ?

    function sendHermes(param){

    var hermes = new Ajax(
    kontroler,
    {
    method: 'GET',
    initialize:function(){this.fx = new Fx.Style($
    (content),'opacity',
    {duration:1000,wait:false});},
    data:{section:param},
    update:$(content),
    onRequest:function(){this.fx.start(1,0);},
    onComplete:function(){this.fx.start(0,1);}

    });

    hermes.request();

    }

    thank you for help
    Piotr Kaleta, Apr 21, 2008
    #1
    1. Advertising

  2. Piotr Kaleta

    Piotr Kaleta Guest

    i mean

    fade out
    load
    fade in :D
    Piotr Kaleta, Apr 21, 2008
    #2
    1. Advertising

  3. Piotr Kaleta

    Henry Guest

    On Apr 21, 7:48 am, Piotr Kaleta wrote:
    > Hi I tried to load asynch. request in that order :
    >
    > fade in div,
    > put response into div,
    > fade out div
    >
    > problem is i get that order :
    >
    > response goes into div,
    > fade in div,
    > fade out div
    >
    > what is the problem ?
    >
    > function sendHermes(param){
    >
    > var hermes = new Ajax(
    > kontroler,
    > {
    > method: 'GET',
    > initialize:function(){this.fx = new Fx.Style($
    > (content),'opacity',
    > {duration:1000,wait:false});},
    > data:{section:param},
    > update:$(content),
    > onRequest:function(){this.fx.start(1,0);},
    > onComplete:function(){this.fx.start(0,1);}
    >
    > });
    >
    > hermes.request();
    >
    > }
    >
    > thank you for help


    What help do you expect when you have not included the code that
    defines Ajax or its methods, Fx, Fx.Stye, the methods of Fx.Style or
    the $ function, and not shown how you call this code or the context
    from which it is called? As it is there is not even evidence that it
    does what you claim it does, let alone enough to determine why it may
    not do what you want it to do.
    Henry, Apr 21, 2008
    #3
  4. Piotr Kaleta

    Piotr Kaleta Guest

    ekhm ... MOOTOOLS , if you don't know it sorry I won't be pasting
    docs from mootools.net manuals
    Piotr Kaleta, Apr 21, 2008
    #4
  5. Piotr Kaleta

    Henry Guest

    On Apr 21, 4:22 pm, Piotr Kaleta <> wrote:
    > ekhm ... MOOTOOLS , if you don't know it sorry  I won't
    > be pasting docs from mootools.net manuals


    Manuals are only any good if the people who wrote them understand the
    code they are documenting. What you should post is the code that is
    relevant to your problem (in isolation from anything that is
    irrelevent).
    Henry, Apr 21, 2008
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. hon123456
    Replies:
    1
    Views:
    421
    Thomas 'PointedEars' Lahn
    Apr 12, 2006
  2. Jake Barnes
    Replies:
    6
    Views:
    194
    Evertjan.
    Sep 3, 2006
  3. Jean Ceugniet

    Mootools, ajax and checkboxes

    Jean Ceugniet, Dec 10, 2007, in forum: Javascript
    Replies:
    10
    Views:
    316
    pixelchutes
    Jan 20, 2008
  4. MZ
    Replies:
    0
    Views:
    139
  5. ameshkin
    Replies:
    4
    Views:
    195
    Thomas 'PointedEars' Lahn
    Jul 22, 2008
Loading...

Share This Page