cancel
Showing results for 
Search instead for 
Did you mean: 

Dropdown menu for country and state not working for Shipping address

Dropdown menu for country and state not working for Shipping address

Cant seem to figure out what is going on with the shipping address drop down selection for checkout.  It seems to add a disabled function, but works perfectly when attempting to send to billing address.

 

here is what it shows.  But cant figure out what is disabling it:

 

<select onchange="if(window.shipping)shipping.setSameAsBilling(false);" title="Country" class="validate-select" id="shipping:country_id" name="shipping[country_id]" disabled=""><option selected="selected" value=""> </option>

4 REPLIES 4

Re: Dropdown menu for country and state not working for Shipping address

Ran across a similar issue, but ours started happening after everything had been functioning properly.

 

What we found was that in the core_config_data table, for some reason, there came to be an entry in there with a path of "general" (with nothing after it, or maybe "/general/")...

 

Point is, since it was one of the last entries, Magento treats that as create (in this case overwrite) the XML node "general" in the core_config that it builds, essentially wiping out all other data in that branch of the XML object.

 

If you find this entry in the table, you should backup the table (always be safe), and remove that entry. Then clear your cache, and you should find that things are back to normal.

 

We never did identify HOW the entry came to exist in the table, but that was the fix for us.

Re: Dropdown menu for country and state not working for Shipping address

I have been searching for a solution to this for months, THANK YOU!

Re: Dropdown menu for country and state not working for Shipping address

was hopefull that this would work, as did for many.  No record in table.  Any other ideas?

Re: Dropdown menu for country and state not working for Shipping address

@AcousticRand 

 

A very likely cause of this is someone accidentally adding the row in whatever MySQL client they use. Magento1 sets defaults for new rows, which happen to use `general` as the path by default if one is not provided. Combine that with someone browsing the admin config in their favourite MySQL client and benignly double-clicking somewhere in the client (often by accident or just plain habit), and you produce this result, as many MySQL clients will insert a new row of data; given that no data was provided, it falls back to the defaults.

 

Have a look at the table `CREATE` syntax for the `core_config_data` table:

 

CREATE TABLE `core_config_data` (
  `config_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Config Id',
  `scope` varchar(8) NOT NULL DEFAULT 'default' COMMENT 'Config Scope',
  `scope_id` int(11) NOT NULL DEFAULT '0' COMMENT 'Config Scope Id',
  `path` varchar(255) NOT NULL DEFAULT 'general' COMMENT 'Config Path',
  `value` text COMMENT 'Config Value',
  PRIMARY KEY (`config_id`),
  UNIQUE KEY `UNQ_CORE_CONFIG_DATA_SCOPE_SCOPE_ID_PATH` (`scope`,`scope_id`,`path`)
) ENGINE=InnoDB AUTO_INCREMENT=2322 DEFAULT CHARSET=utf8 COMMENT='Config Data';