Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Page 1 of 2
Disable State/Province validation
 
ralphie
Member
 
Total Posts:  59
Joined:  2007-12-20
London
 

Hi

I am sure many of you don’t need the state/province field, hence would like to leave it out of the form as well as not having it validated.

however it seems really deep down integrated, incl. server side validation etc.

does any one of you know how to get rid of this field in a clean way? Is there one?

Cheers,

Ralph

 
Magento Community Magento Community
Magento Community
Magento Community
 
lisali
Enthusiast
 
Avatar
Total Posts:  889
Joined:  2008-04-28
London, UK
 

Hey - I need this too.

I thought there was a post somewhere here on how to disable those fields, as I remember having tried in in my test installation. It worked then - but I can not remember what I did or where the post is...AAAARGH!

Lisa

 
Magento Community Magento Community
Magento Community
Magento Community
 
lisali
Enthusiast
 
Avatar
Total Posts:  889
Joined:  2008-04-28
London, UK
 

Ok - I have tried this below and it seems to work - please test and let me know:

Make a BACKUP of:

app/design/frontend/default/default/template/checkout/cart/shipping.phtml

As we need to edit the original like this - comment out or delete the lines between and including:

<?php //if($this->getStateActive()): ?>
.....
<input class="input-text" type="text" id="postcode" name="estimate_postcode" value="<?php echo $this->htmlEscape($this->getEstimatePostcode()) ?>” /></p>

In the original file, it’s the lines 25-44.

Cheers!

Lisa

 
Magento Community Magento Community
Magento Community
Magento Community
 
ralphie
Member
 
Total Posts:  59
Joined:  2007-12-20
London
 

hi lisa

yeah.. this seems an issue for us uk developers what smile

anyway.. i ended up just leaving it inside, dont have time to spend on this right now. however.. if you are at the shipping step i guess you just took the fields out in the billing and shipping address step?

i actually did that too, but ended up that countries with state data (check for instance switzerland) could not order anymore.. thats when i put the fields back in, since again, just cant spend more time on this right now..

but do test biling/shipping address with switzerland and see if you can progress at the first place..

let me know if you explore new stuff..

ralph

 
Magento Community Magento Community
Magento Community
Magento Community
 
lisali
Enthusiast
 
Avatar
Total Posts:  889
Joined:  2008-04-28
London, UK
 

Hmm…

Done some more testing, and it does not seem to work...something with javascript not updating the shipping quote.

What did I do the last time so it worked?? (confused)

Lisa

 
Magento Community Magento Community
Magento Community
Magento Community
 
batkins
Jr. Member
 
Avatar
Total Posts:  26
Joined:  2008-05-10
 

I’m having an issue with the one page checkout. When I select “guest” checkout, everything works fine. When I checkout at a registered user and progress from the Billing Information section of checkout to the Shipping Information section, Alert pop-up with “Please enter state/province.” This will not allow me to progress any further in checkout. I have read the JavaScript will be eliminated with the version 1.1 release, but I need to patch this to continue testing. Any help would be greatly appreciated.

Update: I reloaded Magento and started from scratch… this fixed my issue.

 
Magento Community Magento Community
Magento Community
Magento Community
 
lisali
Enthusiast
 
Avatar
Total Posts:  889
Joined:  2008-04-28
London, UK
 

Does anybody know how to properly eliminate the state and city/zipcode fileds from the shipping estimator in the cart?

Many thanks!

Lisa

 
Magento Community Magento Community
Magento Community
Magento Community
 
doctorlogos
Sr. Member
 
Avatar
Total Posts:  178
Joined:  2008-05-06
 

Any advance?

 
Magento Community Magento Community
Magento Community
Magento Community
 
MagentoFan
Jr. Member
 
Total Posts:  10
Joined:  2008-10-20
 
batkins - 17 June 2008 05:38 AM

I’m having an issue with the one page checkout. When I select “guest” checkout, everything works fine. When I checkout at a registered user and progress from the Billing Information section of checkout to the Shipping Information section, Alert pop-up with “Please enter state/province.” This will not allow me to progress any further in checkout. I have read the JavaScript will be eliminated with the version 1.1 release, but I need to patch this to continue testing. Any help would be greatly appreciated.

Update: I reloaded Magento and started from scratch… this fixed my issue.

in my case, same problem happened after state/province stored in the country region tables. to fix it i changed the customers state/province data to point to the right state/province as stored in the directory_country_region_name and directory_country_region table.

 
Magento Community Magento Community
Magento Community
Magento Community
 
MAGNETO.ME
Jr. Member
 
Total Posts:  12
Joined:  2008-09-09
 
batkins - 17 June 2008 05:38 AM

I’m having an issue with the one page checkout. When I select “guest” checkout, everything works fine. When I checkout at a registered user and progress from the Billing Information section of checkout to the Shipping Information section, Alert pop-up with “Please enter state/province.” This will not allow me to progress any further in checkout. I have read the JavaScript will be eliminated with the version 1.1 release, but I need to patch this to continue testing. Any help would be greatly appreciated.

Update: I reloaded Magento and started from scratch… this fixed my issue.

To solve this , login to your dabase admin and empty the directory_country_region table like this :

TRUNCATE TABLE `directory_country_region`
 
Magento Community Magento Community
Magento Community
Magento Community
 
Jurjen de Vries
Jr. Member
 
Avatar
Total Posts:  21
Joined:  2009-01-08
Utrecht, Netherlands
 

I did a feature request for it @ http://www.magentocommerce.com/boards/viewthread/34487/

 
Magento Community Magento Community
Magento Community
Magento Community
 
Star7591
Jr. Member
 
Total Posts:  12
Joined:  2008-01-11
Switzerland
 

still searching?
Link to MagentoCommerce Forums?

* http://www.magentocommerce.com/boards/viewthread/34487/ external
* http://www.magentocommerce.com/boards/viewthread/10948/ external changed: \\

1. app/code/local/mage/customer/model/address/abstract.php (comment out section with “region")

2. app/design/frontend/default/coolprint/template/checkout/onepage/billing.phtml (remove <span class="required">*</span>)

3. app/design/frontend/default/coolprint/template/checkout/onepage/shipping.phtml (remove <span class="required">*</span>)

4. app/design/frontend/default/coolprint/template/customer/address/edit.phtm (not done, not used) 5. check adjware region is active and same files have span-class_required removed and “display=hidden”

 
Magento Community Magento Community
Magento Community
Magento Community
 
lazzo
Jr. Member
 
Avatar
Total Posts:  10
Joined:  2009-09-07
Malmö, Sweden
 

Concerning the region problem discussed above, is there anyone that installed and got this module to work? http://www.magentocommerce.com/extension/packages/module/1826/mxperts--noregion

I guess it should handle the same issue as described in this thread- but with no need to hack the code. However, after installation on my site, I could not figure how to activate/use it. And the documenation seems to be left out (suprise).  grin

 
Magento Community Magento Community
Magento Community
Magento Community
 
ajaferreira
Jr. Member
 
Total Posts:  9
Joined:  2010-09-11
 

Just for future reference: the solution from MXperts does work and there is no need to activate it! All you have to do is copy the files/folders installed to the same directories in your template (there is 1 xml file and a folder, both named noregion).

Cheers

 
Magento Community Magento Community
Magento Community
Magento Community
 
16325860903
Sr. Member
 
Avatar
Total Posts:  163
Joined:  2011-02-02
Warsaw, Poland
 

Hi, GoMage LightCheckout allows you enable/disable fields like Company, Country, City, Telephone, Fax, Region, Street or Postcode

More details and live demo are here: GoMage LightCheckout 2.0

 
Magento Community Magento Community
Magento Community
Magento Community
 
lukso
Jr. Member
 
Total Posts:  26
Joined:  2009-12-05
 

if you don’t know how to remove state/province field field, you can use this cheap extension. It’s easy to remove state/province fields and this extension also remove Fax field. I use it in my 2 stores and works great.

http://www.magentocommerce.com/magento-connect/catalog/product/view/id/10456/

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 2