Re: [jQuery] FadeOut > Ajax Post > FadeIn problem

2009-12-12 Thread David Day
Oops! Make that... otherwise you get nested divs. $("#menuJ a").click(function(){ var js = $(this); $("#pageArticle").fadeOut(500, function() { $.post( js.attr("href"), null, function(response) { $("#pageArticle").html(response); $("#pageArticle").fadeIn(500); }, "html"); });

Re: [jQuery] FadeOut > Ajax Post > FadeIn problem

2009-12-12 Thread David Day
Thanks Brian The working script is as follows: $("#menuJ a").click(function(){ var js = $(this); $("#pageArticle").fadeOut(500, function() { $.post( js.attr("href"), null, function(response) { var bob = "" + response + ""; $("#pageArticle").html(bob); $("#pageArticle").f

Re: [jQuery] FadeOut > Ajax Post > FadeIn problem

2009-12-12 Thread brian
I believe the sudden appearance is due to the fact that the new div was not hidden. But, a better approach would be to not replace the #pageArticle div. Instead, replace its contents, then fade it in. On Fri, Dec 11, 2009 at 5:02 PM, S9DD wrote: > Hi Folks > > This script fades out a div tag with

[jQuery] FadeOut > Ajax Post > FadeIn problem

2009-12-11 Thread S9DD
Hi Folks This script fades out a div tag with id #pageArticle, gets fresh content from an anchor ajax post, and is Supposed to fade the new content in. But it won't handle from replaceWith onwards properly. New content just suddenly appears. Is there a way to get around this? I have tried opaci