PropioWeb Posted February 3, 2004 Share Posted February 3, 2004 I keep getting customers who call up saying that the state field is screwing them up. When you first register the State field is a field but when they submit it returns them back with an error and the State field is now a Dropdown list with all the states listed. When they select the state from the list it then goes on to reset the form and the customer is forced to input all the info once again. Though it's not a big deal to write all of the info again it is getting quite annoying to field these phone calls. Why isn't the field a dropdown list in the first place? Is this an option so people in other countries can also register? Will this happen only if the state name is misspelled? I tried it out and it did not bump me back to the page. I'm assuming some of the customers are spelling the name wrong. Thanks in advanced. Samuel Mateo, Jr. osC 2.2 MS2 Installed Mods: WYSIWYG HTMLArea 1.7 | Basic Template System 1.0 | osC-Affiliate | OSC-SupportTicket Featured Products 1.3 | LoginBox 5.2 | LatestNews 1.1.3 | Extras for IE Link to comment Share on other sites More sharing options...
PropioWeb Posted February 4, 2004 Author Share Posted February 4, 2004 ^^^ Samuel Mateo, Jr. osC 2.2 MS2 Installed Mods: WYSIWYG HTMLArea 1.7 | Basic Template System 1.0 | osC-Affiliate | OSC-SupportTicket Featured Products 1.3 | LoginBox 5.2 | LatestNews 1.1.3 | Extras for IE Link to comment Share on other sites More sharing options...
PropioWeb Posted February 5, 2004 Author Share Posted February 5, 2004 Anyone? Samuel Mateo, Jr. osC 2.2 MS2 Installed Mods: WYSIWYG HTMLArea 1.7 | Basic Template System 1.0 | osC-Affiliate | OSC-SupportTicket Featured Products 1.3 | LoginBox 5.2 | LatestNews 1.1.3 | Extras for IE Link to comment Share on other sites More sharing options...
Guest Posted February 5, 2004 Share Posted February 5, 2004 Try removing the ZONE on your admin configuation page. If this is blank I don't think it will do it...........give it a try Link to comment Share on other sites More sharing options...
ozcsys Posted February 5, 2004 Share Posted February 5, 2004 I keep getting customers who call up saying that the state field is screwing them up. When you first register the State field is a field but when they submit it returns them back with an error and the State field is now a Dropdown list with all the states listed. When they select the state from the list it then goes on to reset the form and the customer is forced to input all the info once again. Though it's not a big deal to write all of the info again it is getting quite annoying to field these phone calls. Why isn't the field a dropdown list in the first place? Is this an option so people in other countries can also register? Will this happen only if the state name is misspelled? I tried it out and it did not bump me back to the page. I'm assuming some of the customers are spelling the name wrong. Thanks in advanced. To get the state dropdown to show up try making these changes to the create_account.php file From this if (ACCOUNT_STATE == 'true') { $zone_id = 0; $check_query = tep_db_query("select count(*) as total from " . TABLE_ZONES . " where zone_country_id = '" . (int)$country . "'"); $check = tep_db_fetch_array($check_query); $entry_state_has_zones = ($check['total'] > 0); if ($entry_state_has_zones == true) { $zone_query = tep_db_query("select distinct zone_id from " . TABLE_ZONES . " where zone_country_id = '" . (int)$country . "' and (zone_name like '" . tep_db_input($state) . "%' or zone_code like '%" . tep_db_input($state) . "%')"); if (tep_db_num_rows($zone_query) == 1) { $zone = tep_db_fetch_array($zone_query); $zone_id = $zone['zone_id']; } else { $error = true; to this: if (ACCOUNT_STATE == 'true') { $zone_id = 0; $check_query = tep_db_query("select count(*) as total from " . TABLE_ZONES . " where zone_country_id = '223" . (int)$country . "'"); $check = tep_db_fetch_array($check_query); $entry_state_has_zones = ($check['total'] > 0); if ($entry_state_has_zones == true) { $zone_query = tep_db_query("select distinct zone_id from " . TABLE_ZONES . " where zone_country_id = '223" . (int)$country . "' and (zone_name like '" . tep_db_input($state) . "%' or zone_code like '%" . tep_db_input($state) . "%')"); if (tep_db_num_rows($zone_query) == 1) { $zone = tep_db_fetch_array($zone_query); $zone_id = $zone['zone_id']; } else { $error = true; You can also find a good thread on the topic at: http://www.oscommerce.com/forums/index.php?showtopic=53879 Hope this helps Richard The Knowledge Base is a wonderful thing. Do you have a problem? Have you checked out Common Problems? There are many very useful osC Contributions Are you having trouble with a installed contribution? Have you checked out the support thread found Here BACKUP BACKUP BACKUP!!! You did backup, right?? Link to comment Share on other sites More sharing options...
Guest Posted February 5, 2004 Share Posted February 5, 2004 this item is in the Wiki Documentation, the best place to look prior to doing anything, adding any contributions, etc. instructions are straight forward on what to do for dealing with countries & states. Link to comment Share on other sites More sharing options...
PropioWeb Posted February 5, 2004 Author Share Posted February 5, 2004 this item is in the Wiki Documentation, the best place to look prior to doing anything, adding any contributions, etc. instructions are straight forward on what to do for dealing with countries & states. I'm sory but the WIKI is very hard for me to understand. I can never find anything I'm looking for, or if I do it takes me forever. I'm not sure if it's the structure of the WIKI or what but I just don't get it very well. If I use the above code will people outside the US be able to register? We don't do much business outside the US but I would still like the option. Thanks for your help. Samuel Mateo, Jr. osC 2.2 MS2 Installed Mods: WYSIWYG HTMLArea 1.7 | Basic Template System 1.0 | osC-Affiliate | OSC-SupportTicket Featured Products 1.3 | LoginBox 5.2 | LatestNews 1.1.3 | Extras for IE Link to comment Share on other sites More sharing options...
PropioWeb Posted February 5, 2004 Author Share Posted February 5, 2004 OK, the code in the other link worked, I know have the drop down list. I have one last question. I ship to Puerto Rico, probably the only place outside the US I ship to, where in the code can I add the cities or towns from Puerto Rico? Thanks Samuel Mateo, Jr. osC 2.2 MS2 Installed Mods: WYSIWYG HTMLArea 1.7 | Basic Template System 1.0 | osC-Affiliate | OSC-SupportTicket Featured Products 1.3 | LoginBox 5.2 | LatestNews 1.1.3 | Extras for IE Link to comment Share on other sites More sharing options...
ozcsys Posted February 6, 2004 Share Posted February 6, 2004 OK,the code in the other link worked, I know have the drop down list. I have one last question. I ship to Puerto Rico, probably the only place outside the US I ship to, where in the code can I add the cities or towns from Puerto Rico? Thanks Puerto Rico is probably already showing up in the state list. If it is not go into your database and look under zones and make sure the Zone_country_id for Puerto Rico is set for 223. Hope this helps Richard The Knowledge Base is a wonderful thing. Do you have a problem? Have you checked out Common Problems? There are many very useful osC Contributions Are you having trouble with a installed contribution? Have you checked out the support thread found Here BACKUP BACKUP BACKUP!!! You did backup, right?? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.