Wordpress は、ギャラリーの投稿へのリンクを生成しています。
<ul>
<li><a href="/link/to/whatever" class="gallery-link">I Am A Gallery!</a></li>
<li><a href="/link/to/whatever-2" class="gallery-link">I Am Another Gallery!</a></li>
</ul>
リンクが投稿ページに移動するのではなく、コンテンツ (.entry-content) をリンクのリストの上の div (#result) にロードします。
jQuery( document ).ready(function() {
    jQuery(".gallery-link").click(function() { 
        var $target = jQuery(this).attr("href"); //get the URL where the content is
        jQuery("#result").empty() // if the div has stuff in it, get rid of it
        jQuery("#result").css( { 'background-image': 'url(http://staging.caterernyc.com/wp-content/themes/caterer/images/ajax-loader.gif)', 'background-repeat': 'no-repeat', 'background-position': 'center', 'min-height': '200px'  } ); // show the loading gif while the .entry-content is being loaded
        jQuery("#result").load(this.href+" .entry-content", function() { // load the content
                    jQuery("#result").css('background-image', 'none');  // remove the loading gif
        });
        return false;
    });
});
これは機能しますが、私がやりたいのは、コンテンツが表示されるだけでなく、 #result div を簡単に開くことです。私が試したことはまだありません。これは可能ですか?私はこれについてすべて間違っていますか?