これは、「アイコン」のマウスオーバーごとに html と css を事前定義できるメソッドです。
ライブ版: http://jsfiddle.net/gSAjV/2240/
var content1 = '<p>This is some html that will fill the content window</p>';
var content2 = '<p>This is more html that will fill the content window</p>';
var content3 = '<p>This is other html that will fill the content window</p>';
var content4 = '<p>This is even more html that will fill the content window</p>';
$('#icon1').mouseover(function(){
$('#content').html(content1);
$('#content').css( "background-color", "red" );
});
$('#icon2').mouseover(function(){
$('#content').html(content2);
$('#content').css( "background-color", "orange" );
});
$('#icon3').mouseover(function(){
$('#content').html(content3);
$('#content').css( "background-color", "yellow" );
});
$('#icon4').mouseover(function(){
$('#content').html(content4);
$('#content').css( "background-color", "green" );
});
これは機能しますが、私の知る限り、div コンテンツを変更するときにクリーンなトランジションを追加することははるかに困難です。フェードやその他の「A」から「B」へのトランジションが必要な場合は、提案したように、すべてのコンテンツを複数の階層化された div にプリロードすることをお勧めします。
2 つの div のみを使用してトランジションを作成することもできます。1 つの div は現在のコンテンツを保持し、もう 1 つはマウスオーバーで新しいコンテンツをロードし、ロードされるとフェード (トランジション) します。