Adding 2 Functions to One Click
<p>I have this code I've written, It's for a form, and it copies information from the top of the form to the bottom if a checkbox is clicked, and then changes it if any information is changed in the top form.  Now I want to make the bottom form un-editable by the user if the checkbox is clicked, and leave the top one accessible, but I want to do it within the same click statement.  The way I had it written entirely disabled the functionality, I had, and I was wondering if anyone could chime in with any ideas on how to resolve this...</p>

<pre><code> $("#Referral_SameAsAbove_T").click(function(){ 
    if ($("#Referral_SameAsAbove_T").is(':checked')) 
    { 
        // Checked, copy values 
        $("#Referral_PayToAddress_T").val($("#Referral_Address_T").val()); 
        $("#Referral_PayToCity_T").val($("#Referral_City_T").val()); 
        $("#Referral_PayToState_T").val($("#Referral_State_T").val()); 
        $("#Referral_PayToZip_T").val($("#Referral_Zip_T").val()); 
        $("#Referral_PayToAddress_T,#Referral_PayToCity_T,#_Referral_PayToState_T,#Referral_PayToZip_T").val('').attr('editable', false);
    } 
    else 
    { 
        // Clear on uncheck 
        $("#Referral_Address_T").val(""); 
        $("#Referral_City_T").val(""); 
        $("#Referral_State_T").val(""); 
        $('#Referral_PayToAddress_T,#Referral_PayToCity_T,#_Referral_PayToState_T,#Referral_PayToZip_T').attr('editable', true);
    } 
}); 
</code></pre>
