I am trying to overwrite fields with stored adresses in the following page. But its not working as though not giving any errors. Do you see anything wrong here?
$(function() { $("input#copyshipping").click(function(){ if ($("input#copyshipping").is(':checked')) { // Checked, copy values $("input#BillingFirstName").val("<%=Session ("ShippingFIRSTNAME")%>"); $("input#BillingLastName").val("<%=Session ("ShippingLASTNAME")%>"); $("input#BillingAddress1").val("<%=Session("ShippingADDRESS1") %>"); $("input#BillingAddress2").val("<%=Session ("ShippingADDRESS2")%>"); $("input#BillingCity").val("<%=Session("ShippingCITY") %>"); $("input#BillingState").val("<%=Session("ShippingSTATE") %>"); $("input#BillingCountry").val("<%=Session ("ShippingPOSTALCODE")%>"); $("input#BillingPostalCode").val("<%=Session ("ShippingCOUNTRY")%>"); } else { // Clear on uncheck $("input#BillingFirstName").val(""); $("input#BillingLastName").val(""); $("input#BillingAddress1").val(""); $("input#BillingAddress2").val(""); $("input#BillingCity").val(""); $("input#BillingState").val(""); $("input#BillingCountry").val(""); $("input#BillingPostalCode").val(""); } }); });