This is a discussion on weird problem when customer creates account within the osCMax v1.7 Discussion forums, part of the osCMax v1.7 Forums category; Hi I have installed all the uk counties as zones, and set the default country to UK (222), however, when ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Hi I have installed all the uk counties as zones, and set the default country to UK (222), however, when i try to create a new customer account the field for Sate (which is my County field) is a plain text box. However, if I make a mistake in the form and it refreshes, the State field then becomes the drop down box that I want with all my counties in it as it should be. Beneath is the code pertaining to 'state' in create_account_tpl.php - can anyone see what is wrong, cos I have spent all day on this and for the life of me cant find it. Quote:
cheers for any help Kim
__________________ Google says be nice! |
| Sponsored Links | ||
| ||
|
#2
| ||||
| ||||
| This is an annoying bug that has been in osCommerce for a long time. This mod fixes it: http://www.oscommerce.com/community/...,country+state
__________________ Michael Sasek osCMax Developer
|
|
#3
| |||
| |||
| Cheers Michael I have done as you suggested (don't I always) and I have made a clean install of the country and state mod and I now have it working. I installed the latest edition with all the extra stuff in the javascript file. There is a nice dropdown box now for 'state' However, i am still coming up with another problem: When I change country, the page does not refresh the state drop down box. For example, my default is united kingdom, and if I change the country using the dropdown box from that to (for instance) the USA, the zones in the 'state' dropdown box remain UK counties and not US states. I have 2 form_check.js.php files (presumably cos MAX uses BTS) and I have added the new code (as per the mod) to both of them. I use the latest firefox, but have tested in IE6 also and the problem is the same, no refresh of 'states' dropdown box. Bit of a setback if someone outside the UK wants to use it! Any help or suggestions would be greatly appreciated. Cheers kim
__________________ Google says be nice! |
|
#4
| ||||
| ||||
| You need to specifically add this to your main_page.tpl.php file in the <head> section: Code: <?php require('includes/javascript/form_check.js.php'); ?>
__________________ Michael Sasek osCMax Developer
|
|
#5
| |||
| |||
| Cheers Michael I so much wanted to say whoopeee, thats cracked it but.... I tried it in head under the following code <?php if ($javascript) { require(DIR_WS_JAVASCRIPT . $javascript); }?> and then at the top of the head section, but no change, either in IE6 or Firefox. I know there was an issue with Javascript with the XP sp2 upgrade, but I have checked it on a machine that escaped that upgrade, and it still doesnt refresh at all
__________________ Google says be nice! |
|
#6
| ||||
| ||||
| Put it above <?php if ($javascript) { require(DIR_WS_JAVASCRIPT . $javascript); }?> and it will work. If not, make sure you have correctly added the function to includes/javascript/form_check.js.php I have it working in the dev version of osCMax and that is the exact issue I had. It will work for you eventually. Basically, the problem is that your template is loading form_check.js.php or trying to, but it cannot find the page refresh function. I suggest debugging in Firefox. Load the page, try to change the country and then open the Firefox Javscript console. You will see an error telling you what the issue is.
__________________ Michael Sasek osCMax Developer
|
|
#7
| |||
| |||
| Thanks Michael, whoopee, sorted. The problems were that :-because of BTS, some of the new code had to go in template files instead of the create_account.php... in fact the instructions for modding that file for MAX should indicate 3 files...mainpage.tpl.php, create_account.tpl.php and create_account.php. Maybe I should add a readme file for MS2 MAX so that people here can mod for this contribution more easily. Although if people are paying attention, if they pull up those files in Dreamweaver they can do it with a Find - Replace function, so long as they check on each file. thanks loads Kim
__________________ Google says be nice! |
| Sponsored Links | ||
| ||
| |
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Email not sent after new customer account is created. | Dumb_Question | osCMax v2 Installation issues | 7 | 12-16-2005 04:37 PM |
| Weird problem | Walter | osCommerce 2.2 Modification Help | 0 | 06-14-2004 04:43 PM |
| customer account requirements | cutxpaste | osCommerce 2.2 Modification Help | 3 | 11-07-2003 08:51 PM |
| Weird problem >>> editing some products and categor | Anonymous | osCMax v1.7 Discussion | 0 | 10-27-2003 11:21 AM |