Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

ZipCode Validation Module

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #21  
Old 06-14-2004, 02:07 PM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

Is the file "validate_zipcode.php" in the same directory as "include/register.php"?

Also, what is the PHP code on line 116 and 197 in register.php?
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
  #22  
Old 06-14-2004, 02:19 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

Yes validate_zipcode.php is in the same directory (include)
(before removing @):
Code:
116= if (@include('validate_zipcode.php')) { 197= # Add new person to customers table
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
  #23  
Old 06-14-2004, 02:24 PM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

What is the line directly above 197 ??

UPDATE: Nevermind, see what I wrote in the next post.
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
  #24  
Old 06-14-2004, 02:31 PM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

Change...
Code:
include('validate_zipcode.php')
...to...
Code:
include($xcart_dir.'/include/validate_zipcode.php')

That should fix the problem!
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
  #25  
Old 06-14-2004, 03:05 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

IT WORKED!!! It caught the P0H 1A error but it also wanted me to fill in the shipping address "first name", "last name" fields? When I tyed the postal code correctly though, it no longer asked for those fields???
BOTTOM LINE... IT WORKED!
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
  #26  
Old 06-14-2004, 03:17 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

I think it has something to do with:
Code:
# Fields filled with errors # if (!empty($fillerror)) $reg_error="F"; if (!empty($eerror)) $reg_error="E"; if (!empty($uerror)) $reg_error="U"; } if($anonymous_user) { $uname=""; $passwd1=""; $passwd2="";

I should mention that I am trying to checkout as an anonymous user.

Code:
Zip/Postal code * P0H 1A << ---this is good! Shipping Address (leave empty if same as billing address) -------------------------------------------------------------------------------- Title Mr. Mrs. Ms. First Name .......................... << --not good Last Name.......................... << --not good Address
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
  #27  
Old 06-14-2004, 03:23 PM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

I have had that problem as well. Not sure why, but the registration error checks the shipping names no matter what.

In the file "skin1/main/register_shipping_address.tpl", remove the two lines which starts with "{if $reg_error ne" and that should fix that problem.
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
  #28  
Old 06-14-2004, 03:36 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

I was just in the process of looking for those! I can't thank you enough for for help, THANKS!
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
  #29  
Old 06-14-2004, 03:40 PM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

Quote:
Originally Posted by GM
I was just in the process of looking for those! I can't thank you enough for for help, THANKS!

No prob! At least I am now an "eXpert" on these forums.
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
  #30  
Old 06-14-2004, 03:43 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

You earned it in this thread alone! http://www.goldmisers.com/smiles/thumbsup.gif
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 08:03 PM.

   

 
X-Cart forums © 2001-2020