svn commit: r1372764 - /ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1372764 - /ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl

sascharodekamp
Author: sascharodekamp
Date: Tue Aug 14 08:17:14 2012
New Revision: 1372764

URL: http://svn.apache.org/viewvc?rev=1372764&view=rev
Log:
Fix a bug on the new customer site. Some div's where only renamed in the HTML but not the JS code, the result was an error when using getElementById

Modified:
    ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl

Modified: ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl?rev=1372764&r1=1372763&r2=1372764&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl (original)
+++ ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/newcustomer.ftl Tue Aug 14 08:17:14 2012
@@ -51,10 +51,12 @@ under the License.
          }
      }
      function hideShowUsaStates() {
-         if (document.getElementById('customerCountry').value == "USA" || document.getElementById('customerCountry').value == "UMI") {
-             document.getElementById('customerState').style.display = "block";
+ var customerStateElement = document.getElementById('newuserform_stateProvinceGeoId');
+     var customerCountryElement = document.getElementById('newuserform_countryGeoId');
+         if (customerCountryElement.value == "USA" || customerCountryElement.value == "UMI") {
+             customerStateElement.style.display = "block";
          } else {
-             document.getElementById('customerState').style.display = "none";
+             customerStateElement.style.display = "none";
          }
      }
    //]]>