trying to scale down a click event thats used multiple times for different ids?
<p>Im trying to cut down some code, basically the following click event is used 10 times with the id ranging from #topNavA - #topNavJ, there's only 2 parts of the event that ever changes. Can anyone suggest how I can recycle this code for each click? I've added in comments of the lines that will change from click event to click event but the rest just stays the same? All advice welcome.</p>

<pre><code>$('#topNavA').click(function() {
    $footerPush.hide();
    $allMultipleElements.hide();

    $('#section, #placement, .mobileControls').show(); // This line will change with different selectors
    $('.mobileControls h1').replaceWith('&lt;h1&gt;Mobilizing Mobile, AL&lt;/h1&gt;'); // This line will change with a different header 1
    $('.mobileControls h2').replaceWith('&lt;h2&gt;Overview&lt;/h2&gt;'); // This line will change with a different header 2
    $('.menuTitle').removeClass('active');
    $('.lightbox').remove();

    $('#nav li &gt; a').removeClass('active');
    $('#nav li span a').css({
        'color': '#8F8F8F'
    });

    $('#topNav').addClass('active');
    $(this).css({
        'color': '#e8af20'
    });
});
</code></pre>

<p>Thanks
Kyle</p>
