Question about a jQuery command in Wordpress archive.php

Question about a jQuery command in Wordpress archive.php

I am using a Wordpress portfolio theme (Contrast) for a music website and I've come across what I suspect is a relatively easy coding question - easy for someone familiar with jQuery unlike me!

In the archive.php the portofolio (a user-selected category) generates a nifty series of bars on the right hand margin with tiel, page meta information, a hyperlink to the post containing details and a thumbnail  of the full image. Through an .ajax command, clicking the thumbnail results in replacing the current background with the full image from the post, but keeps the navigation in place. This makes sense for a portfolio, but since on this website the image is less important than the post, which contains a bio and sometimes embedded audio, I would like to change it so the click goes directly to the post. I would have thought this would be quite easy, but thus far I have been unable to correctly modify the code.

I am guessing that the ajax would be unnecessary, since the entire page will be re-loading in any case, but I don't know what needs to be replaced and what needs to stay. I have copied the entire javascript/text below and boldfaced the specific code for the action I want to change.

(The load_background.php is one line calling the BG_image which is entered as a custom field into each post. I assume it would not be necessary in what would essentially be a link to 'the_permalink'.)

I would be extremely grateful for help on this as I am quite behind a deadline on this. I hope I have provided enough information. Thanks!


        <script type="text/javascript">
            $(document).ready(function() {
                $('.nav.portfolio .navMask ul.navContent, .menu, .footer').hover(function() {
                    $('.nav.portfolio .navMask ul.navContent').animate({right: '0px'}, {queue:false, duration: 500});
                    $('.menu, .footer').animate({opacity: '1'}, {queue:false, duration: 500});
                },
                function(){
                    $('.nav.portfolio .navMask ul.navContent').animate({right: '-200px'}, {queue:false, duration: 300});
                    $('.menu, .footer').animate({opacity: '0.1'}, {queue:false, duration: 300});
                });
               
                $('.nav.portfolio .navMask ul.navContent li p.image a').click(function() {
                    $('.loading').show();
                    $.ajax({
                        type: 'GET',
                        url: '<?php bloginfo('template_url'); ?>/load_background.php',
                        data: 'BG_image=' + $(this).attr('rel'),
                        success: function(html) {
                            $('#background').html(html);
                           
                            $('#background img').load(function() {
                                $(this).css({
                                    top: ($(window).height() - $(this).height()) / 2,
                                    display: 'block'
                                });
                               
                                $('.loading').hide();
                            });
                        }
                    });
                });
               
                $('.nav.portfolio .navMask ul.navContent li p.image a:eq(0)').click();
            });
        </script>