ボタンのクリックによってトリガーされる短い jQuery アニメーションを含むランディング ページがあり、アニメーションが終了した後、サーバー上の別のページにリダイレクトしたいのですが、ランディング ページから別のページにフェードさせたいのです。
現在、他のページにリダイレクトする直前にドキュメント本文をフェードするように設定していますが、フェードが始まると色付きの背景ではなく白い背景が見えるように白にフェードします。この効果を達成するためのより良い方法があると思います。
これが私の現在のコードです:
$(document).ready(function(){
$("#button").click(function(){
$(".left").animate(
{left:'50%'}, 800, 'linear'
);
$(".right").animate(
{right:'50%'}, 800, 'linear'
);
$(".top").stop(true, true).delay(800).animate(
{top:'36px'}, 800, 'easeOutBounce'
);
$(".bot").stop(true, true).delay(800).animate(
{top:'492px'}, 800, 'easeOutBounce'
);
$(document.body).delay(1900).fadeTo("slow", 0);
setTimeout(function ()
{ window.location.href = "start.php"; }, 2000);
});
});