Community Forums

How can I make the "postcode" required when registering?

General support for technical problems with OpenCart v1.x

Re: How can I make the "postcode" required when registering?

Postby chapstick » Sat Jan 02, 2010 5:57 pm

Rafael wrote:When checking out (OpenCart 1.3.2), and at delivery information I clicked on "change address"



When I do this, my postcode isn't required, so in theory someone could remove their postcode at this step.
chapstick
 
Posts: 13
Joined: Wed Oct 28, 2009 2:26 pm

Re: How can I make the "postcode" required when registering?

Postby Qphoria » Sat Jan 02, 2010 6:54 pm

chapstick wrote:
Rafael wrote:When checking out (OpenCart 1.3.2), and at delivery information I clicked on "change address"



When I do this, my postcode isn't required, so in theory someone could remove their postcode at this step.


which is why it is important to read the whole thread:
viewtopic.php?f=20&t=6129#p29382
Image Image
Donate!|OpenCart Basics|GeoZones
Help me get more development cloud storage - Click Here to get DropBox
User avatar
Qphoria
Administrator
 
Posts: 18199
Joined: Mon Jul 21, 2008 7:02 pm
Donate to Qphoria

Re: How can I make the "postcode" required when registering?

Postby nocko » Tue Feb 09, 2010 8:59 pm

Beautiful! This post should be published or the option should be included in the final code :-X
nocko
 
Posts: 24
Joined: Tue Jan 26, 2010 6:14 am

Re: How can I make the "postcode" required when registering?

Postby deeve » Mon Mar 01, 2010 11:17 am

Very cool - thanks, guys! ;)
deeve
 
Posts: 250
Joined: Tue Oct 20, 2009 8:31 am

Re: How can I make the "postcode" required when registering?

Postby JordyC » Sun Apr 04, 2010 7:00 pm

Is or Will this be in one of the offical OpenCart updates? If not then ill mod it using the code given in the thread but I give a Thumbs up to it being in the offical update.
JordyC
 
Posts: 12
Joined: Sun Apr 04, 2010 6:56 pm

Re: How can I make the "postcode" required when registering?

Postby junstore » Tue Apr 13, 2010 3:14 pm

it will be wonderful if opencart can publish a stable version like zc 1.38a, it hard to use if we want some modifications and need we know some db and php, but it is still awesome that daniel did a god job
Created my future by opencart~
junstore
 
Posts: 21
Joined: Thu Apr 08, 2010 1:41 pm
Location: China

Re: How can I make the "postcode" required when registering?

Postby kedgetech » Mon Apr 26, 2010 8:39 am

Works like a Charm (using 1.4.4)
Last edited by kedgetech on Sun Aug 22, 2010 2:41 am, edited 1 time in total.
User avatar
kedgetech
 
Posts: 637
Joined: Mon Mar 22, 2010 9:20 am
Location: USA, Australia, India

Re: How can I make the "postcode" required when registering?

Postby chriszammett » Fri May 07, 2010 2:31 pm

I keep getting this error on my contact page

have followed the steps several times but keep hitting the same problem

Notice: Undefined variable: error_postcode in /customers/ghd-spares.com/ghd-spares.com/httpd.www/catalog/view/theme/default/template/account/create.tpl on line 81
chriszammett
 
Posts: 32
Joined: Wed Apr 07, 2010 1:17 pm

Re: How can I make the "postcode" required when registering?

Postby Purebeads » Tue May 11, 2010 5:06 am

I just want to add my voice that I would like to see the postal code be required. However, if you have the city and state (or city and province, etc.), you can generally look it up on the internet.

One other thing: In some languages, such as Chinese, 2-letter city names can occur. I think that making 3 letters the minimum for that field is not a good idea.
Purebeads
 
Posts: 368
Joined: Fri Apr 30, 2010 4:07 am

Re: How can I make the "postcode" required when registering?

Postby kedgetech » Tue May 11, 2010 1:18 pm

chriszammett - You missed a file to change or add the content. Try to re-visit all the files you should be alright.

Purebeads - I think thats a good idea to have the zip code mandated but I would dont see the greater good adding all the zipcodes of all countries to be added to OC and comes with maintenance of changing/in correct zip codes.
I would say changing city name validation is simple customization good catch though.
Image
OpenCart Development, Customization, Upgrades, Integration, Support, SEO, SSL
CMS|Price Match|Product Catalog|Product Bundle|Product Enhancements|Paypal Restrictions
User avatar
kedgetech
 
Posts: 637
Joined: Mon Mar 22, 2010 9:20 am
Location: USA, Australia, India

Re: How can I make the "postcode" required when registering?

Postby Purebeads » Wed May 12, 2010 7:25 pm

I didn't mean to say that OpenCart should have a list of postal codes. I was just making a general comment that postal codes can be found on the internet -- so if a customer leaves it off, the merchant can still find it.
Purebeads
 
Posts: 368
Joined: Fri Apr 30, 2010 4:07 am

Re: How can I make the "postcode" required when registering?

Postby Joxe » Mon May 17, 2010 6:27 pm

Is the code given working for 1.4.7? I'd like to make post code a required field either with customer registration or guest checkout...
In terms of shipping, postcodes are important so I think it should be a required field in next OC version. ;)
v. 1.4.9.6 & v. 1.5.1.1
Joxe
 
Posts: 202
Joined: Tue Apr 27, 2010 10:12 pm

Re: How can I make the "postcode" required when registering?

Postby dannydaman9 » Tue May 25, 2010 10:32 am

Joxe wrote:Is the code given working for 1.4.7? I'd like to make post code a required field either with customer registration or guest checkout...
In terms of shipping, postcodes are important so I think it should be a required field in next OC version. ;)


I'm using 1.4.7 and works ok. However i think i missed something as when i click continue, it stays on the page but doesn't display an error message to notify the user about the postcode. Also there is no asterisk near postcode.

Have i missed something or does something else need to be implemented?

Thanks
User avatar
dannydaman9
 
Posts: 73
Joined: Tue May 11, 2010 11:00 am
Location: Manchester, England

Re: How can I make the "postcode" required when registering?

Postby dramony » Wed May 26, 2010 6:27 am

dannydaman9 wrote:
I'm using 1.4.7 and works ok. However i think i missed something as when i click continue, it stays on the page but doesn't display an error message to notify the user about the postcode. Also there is no asterisk near postcode.

Have i missed something or does something else need to be implemented?

Thanks


Maybe you missed this:

Code: Select all
3. EDIT: catalog/language/english/account/create.php
FIND:

Code: Select all
    $_['error_city']           = 'City must be greater than 3 and less than 128 characters!';


AFTER, ADD:

Code: Select all
    $_['error_postcode']       = 'Postcode must be greater than 1 and less than 10 characters!';
User avatar
dramony
 
Posts: 258
Joined: Sat Oct 24, 2009 4:34 am

Re: How can I make the "postcode" required when registering?

Postby dannydaman9 » Wed May 26, 2010 8:16 am

thats already inputted. double checked it and still no error message pops up
User avatar
dannydaman9
 
Posts: 73
Joined: Tue May 11, 2010 11:00 am
Location: Manchester, England

Re: How can I make the "postcode" required when registering?

Postby dannydaman9 » Wed May 26, 2010 1:02 pm

does anyone have a solution? I'm quite desprate for this now

thanks

EDIT: Fixed it now by myself. works like a charm

thanks
User avatar
dannydaman9
 
Posts: 73
Joined: Tue May 11, 2010 11:00 am
Location: Manchester, England

Re: How can I make the "postcode" required when registering?

Postby dannydaman9 » Fri May 28, 2010 3:38 pm

i now want to be able to make in required in the change address section when ordering a product (i.e. the checkout section) have followed the steps that someone else posted on this thread. It works however i cann't get the error message to appear again. Any help?

thanks
User avatar
dannydaman9
 
Posts: 73
Joined: Tue May 11, 2010 11:00 am
Location: Manchester, England

Re: How can I make the "postcode" required when registering?

Postby funrider » Mon Jun 14, 2010 9:14 am

Isn't a option to have 'postcode/zipcode' a required field build in the options of 1.4.8? I installed 1.4.8 but can't find the option to turn this on. Or best would be to have it a required field when I am running the Dutch language where we use postcode.

I looked in e.g. System > Locolisation > Languages > edit Country

Image
OpenCart is the best Webshop tool! Congratulations with releasing version 1.5
funrider
 
Posts: 65
Joined: Thu Jun 10, 2010 1:19 pm
Location: Netherlands

Re: How can I make the "postcode" required when registering?

Postby Karen » Tue Jun 15, 2010 1:57 pm

dannydaman9 wrote:does anyone have a solution? I'm quite desprate for this now

thanks

EDIT: Fixed it now by myself. works like a charm

thanks


Care to tell us how you fixed it? Am having the same problem.
Using OC version 1.4.8b
http://catandcaboodle.com/
User avatar
Karen
 
Posts: 159
Joined: Thu Jun 10, 2010 6:51 am
Location: WA State, USA

Re: How can I make the "postcode" required when registering?

Postby Moggin » Tue Jun 15, 2010 2:56 pm

This has just been posted (haven't tried it yet):
viewtopic.php?f=2&t=15699&start=40#p78495
==========
EDIT, 21/06/2010:
It works. BIg thanks to OCyvon2 - you're a star!
Moggin
 
Posts: 1079
Joined: Tue May 04, 2010 8:56 pm

PreviousNext

Return to General Support

Who is online

Users browsing this forum: AlGeorge, dereklro, fizfaziq, Haywire, kokoshaggy and 51 guests

Hosted by Arvixe Web Hosting