Commit Graph

170 Commits

Author SHA1 Message Date
Mike Jolley 74f3972e26 Add sort parameter to checkout fields to aid with sorting per locale. 2016-12-12 15:23:28 +00:00
Mike Jolley 52be22511c Inline docs for #12409 2016-11-25 12:24:26 +00:00
Mike Jolley eab41b37f7 Move location of billing email field to work with password managers.
Fixes #11016
2016-11-25 11:32:42 +00:00
flemarie 07752c33bf Update class-wc-countries.php
State is not exist for this country :

- French Guyanne : GF
- Reunion Island : RE
- Mayotte : YT
- Guadeloupe : GP
- Martinique : MQ

Thank you
2016-11-20 22:04:15 +04:00
Mike Jolley 76b32c9aa5 WIP - Product CRUD (#12065)
* Created function to get the catalog visibility options

* First methods for WP_Product crud

* Product set methods

* Fixed several erros while setting data

* First methods for WP_Product crud

* Product set methods

* Fixed several erros while setting data

* Hardcode the get_type per product class

* Initial look through getters and setters and abstract data

* Missing var

* Add related product functions and deprecate those in class.

* No need to exclude ID

* Fixed coding standards and improved the docblocks

* Get cached terms from wc_get_related_terms()

* Fixed wrong variable in wc_get_related_terms

* Use count() instead of sizeof()

* Sanitize ids later

* Remove unneeded comments

* wc_get_product_term_ids instead of related wording and use in other places.

get_the_terms is used here and also handles caching, something
wp_get_post_terms does not.

* Clean up the abstract product class a bit, deprecate two functions we have renamed, make update & create work properly, and add some tests for it.

* Bump template version

* Handle PR feedback: Remove duplicate regular_price update, allow changing of post status for products, remove deprecation for get_title since we might still offer it as a function

* Made abstract function useful

* External Product CRUD

* _virtual meta should be 'no', not taxable, in product unit test helper

* Grouped product class

* Tests

* Move children to meta and update test

* Use get_upsell_ids

* Spacing in query

* Moving and refactoring methods

* Availability html

* Tidy/add todos

* Rename method

* Put back review functions (still todo)

* missing $this

* get_price_including_tax/excluding_tax functions

* wc_get_price_to_display

* Price handling

* [Product CRUD] Variable (#12146)

* [Product CRUD] Variable Products

* Handle PR feedback.

* [Product CRUD] Grouped Handling (#12151)

* Handle grouped product saving

* Update routine

* [Product CRUD] Product crud terms (#12149)

* Category and tag id handling

* Replace template functions

* Remove todo

* Handle default name in save function

* Product crud admin save routine (#12174)

* Initial props

* Work on admin saving

* Set/get attributes

* Atom was moaning about this before but no longer.

* Update get_shipping_class

* WC_Product_Attribute

* Use getter in admin panel

* Fix attribute saving

* Spacing

* Fix comment

* wc_implode_text_attributes helper function

* [Product CRUD] Product crud admin use getters (#12196)

* Initial props

* Work on admin saving

* Set/get attributes

* Atom was moaning about this before but no longer.

* Update get_shipping_class

* WC_Product_Attribute

* Use getter in admin panel

* Fix attribute saving

* Move settings into new files

* Refactor panels and use getters

* Use getters for variation panel

* Revert save variation changes for now

* Add todos

* Fix downloads

* REST API CRUD Updates

* Additional API updates/fixes. Added some todos

* Fix final failing tests and implementing setters/getters and attributes functionality.

* Fix comparison for is_on_sale and remove download_type from WC_Product.

* Add a wc_get_products wrapper.

* Remove the download type input from the product data metabox for downloadable products. (#12221)

* [Product CRUD] Variations - setters, getters and admin. (#12228)

* Started on variation changes

* Stock functions

* Variation class

* Bulk change ->id to get_id() to fix variation form display

* Missing status

* Fix add to cart

* Start on stored data save

* save variation

* Save_variations

* Variation edit panel

* Save variations code works.

* Remove stored data code and fix save

* Improve legacy class

* wc_bool_to_string

* prepare_set_attributes

* Use wc_get_products

* More feedback fixes

* Feedback fixes

* Implement CRUD in the legacy REST API

* Handle PR feedback

* [Product CRUD] Getter setter proxy methods (#12236)

* Started on variation changes

* Stock functions

* Variation class

* Bulk change ->id to get_id() to fix variation form display

* Missing status

* Fix add to cart

* Start on stored data save

* save variation

* Save_variations

* Variation edit panel

* Save variations code works.

* Remove stored data code and fix save

* Improve legacy class

* wc_bool_to_string

* prepare_set_attributes

* Use wc_get_products

* More feedback fixes

* get_prop implementation in abstract and data classes

* Implement set_prop

* Change handling

* Array key exists

* set_object_read

* Use get_the_terms() instead of wp_get_post_terms()

wp_get_post_terms() is a wrapper around wp_get_object_terms() which does not
use the object cache, and generates a database query every time it is used.

get_the_terms() however can use data from the object cache if present.

* Allow WP_Query to preload post data, and meta in wc_get_products()

Allow WP_Query to bulk query for post data and meta if more than
just IDs are requested from wc_get_products(). Reduces query count
significantly.

* [Product CRUD] Variable, variation, notices, and stock handling (#12277)

* No longer needed

* Remove old todos

* Use getters in admin list

* Related and upsells update for CRUD

* Fix notice in gallery

* Variable fixes and todos

* Context

* Price sync

* Revert variation attributes change

* Return parent data in view context

* Defer term counting

* wc_find_matching_product_variation

* Stock manage tweaks

* Stock fixes

* Correct id

* correct id

* Better sync

* Data logic setter fix

* feedback

* First methods for WP_Product crud

* Product set methods

* Fixed several erros while setting data

* Hardcode the get_type per product class

* Initial look through getters and setters and abstract data

* Missing var

* Fixed coding standards and improved the docblocks

* Get cached terms from wc_get_related_terms()

* Fixed wrong variable in wc_get_related_terms

* Use count() instead of sizeof()

* Add related product functions and deprecate those in class.

* No need to exclude ID

* Sanitize ids later

* Clean up the abstract product class a bit, deprecate two functions we have renamed, make update & create work properly, and add some tests for it.

* Remove unneeded comments

* wc_get_product_term_ids instead of related wording and use in other places.

get_the_terms is used here and also handles caching, something
wp_get_post_terms does not.

* Handle PR feedback: Remove duplicate regular_price update, allow changing of post status for products, remove deprecation for get_title since we might still offer it as a function

* External Product CRUD

* _virtual meta should be 'no', not taxable, in product unit test helper

* Bump template version

* Made abstract function useful

* Grouped product class

* Tests

* Move children to meta and update test

* Use get_upsell_ids

* Spacing in query

* Moving and refactoring methods

* Availability html

* Tidy/add todos

* Rename method

* Put back review functions (still todo)

* missing $this

* get_price_including_tax/excluding_tax functions

* wc_get_price_to_display

* Price handling

* [Product CRUD] Variable (#12146)

* [Product CRUD] Variable Products

* Handle PR feedback.

* [Product CRUD] Grouped Handling (#12151)

* Handle grouped product saving

* Update routine

* [Product CRUD] Product crud terms (#12149)

* Category and tag id handling

* Replace template functions

* Remove todo

* Handle default name in save function

* Product crud admin save routine (#12174)

* Initial props

* Work on admin saving

* Set/get attributes

* Atom was moaning about this before but no longer.

* Update get_shipping_class

* WC_Product_Attribute

* Use getter in admin panel

* Fix attribute saving

* Spacing

* Fix comment

* wc_implode_text_attributes helper function

* [Product CRUD] Product crud admin use getters (#12196)

* Initial props

* Work on admin saving

* Set/get attributes

* Atom was moaning about this before but no longer.

* Update get_shipping_class

* WC_Product_Attribute

* Use getter in admin panel

* Fix attribute saving

* Move settings into new files

* Refactor panels and use getters

* Use getters for variation panel

* Revert save variation changes for now

* Add todos

* Fix downloads

* REST API CRUD Updates

* Additional API updates/fixes. Added some todos

* Fix final failing tests and implementing setters/getters and attributes functionality.

* Fix comparison for is_on_sale and remove download_type from WC_Product.

* Add a wc_get_products wrapper.

* Remove the download type input from the product data metabox for downloadable products. (#12221)

* [Product CRUD] Variations - setters, getters and admin. (#12228)

* Started on variation changes

* Stock functions

* Variation class

* Bulk change ->id to get_id() to fix variation form display

* Missing status

* Fix add to cart

* Start on stored data save

* save variation

* Save_variations

* Variation edit panel

* Save variations code works.

* Remove stored data code and fix save

* Improve legacy class

* wc_bool_to_string

* prepare_set_attributes

* Use wc_get_products

* More feedback fixes

* Feedback fixes

* Implement CRUD in the legacy REST API

* Handle PR feedback

* [Product CRUD] Getter setter proxy methods (#12236)

* Started on variation changes

* Stock functions

* Variation class

* Bulk change ->id to get_id() to fix variation form display

* Missing status

* Fix add to cart

* Start on stored data save

* save variation

* Save_variations

* Variation edit panel

* Save variations code works.

* Remove stored data code and fix save

* Improve legacy class

* wc_bool_to_string

* prepare_set_attributes

* Use wc_get_products

* More feedback fixes

* get_prop implementation in abstract and data classes

* Implement set_prop

* Change handling

* Array key exists

* set_object_read

* Use get_the_terms() instead of wp_get_post_terms()

wp_get_post_terms() is a wrapper around wp_get_object_terms() which does not
use the object cache, and generates a database query every time it is used.

get_the_terms() however can use data from the object cache if present.

* [Product CRUD] Variable, variation, notices, and stock handling (#12277)

* No longer needed

* Remove old todos

* Use getters in admin list

* Related and upsells update for CRUD

* Fix notice in gallery

* Variable fixes and todos

* Context

* Price sync

* Revert variation attributes change

* Return parent data in view context

* Defer term counting

* wc_find_matching_product_variation

* Stock manage tweaks

* Stock fixes

* Correct id

* correct id

* Better sync

* Data logic setter fix

* feedback

* Prevent notices

* Handle image_id from parent

* Fix error

* Remove _wc_save_product_price

* Remove todo

* Fixed wrong variation URLs

* Fixed undefined $image_id in WC_Product_Variation::get_image_id()

* Allow wc_rest_prepare_date_response() handle timestamps

* Updated get methods on REST API for variations

* Use variations CRUD to save variations metadata

* [Product CRUD] Abstract todos (#12305)

* Get dimensions and weights, with soft deprecation

* Product attributes

* Ratings

* Fix read method

* Downloads

* Feedback

* Revert "[Product CRUD] Abstract todos (#12305)"

This reverts commit 9a6136fcf8.

* Remove deprecated get_variation_id()

* New default attributes method

* [Product CRUD] Product Datastore (#12317)

* Fix up tests in the product/* folder.

* Handle data store updates for grouped, variable, external, simple, and general data store updates for products.

* Variations & variable changes.

* Update -functions.php calls to use data store.

* Add an interface for the public product data store methods.

* Finished product factory tests

* Correctly delete in the api, fix up some comments, and implement an interface for the public variable methods.

* Fix up delete in all versions of the api

* Handle feedback

* Match protected decloration to parent

* Product crud abstract todos (#12316)

* Get dimensions and weights, with soft deprecation

* Product attributes

* Ratings

* Fix read method

* Downloads

* Feedback

* Fix up store

* Fixed method returning in write context

* Fix error in variation admin

* Check for parent value - fixes tax class

* Remove old/complete todos

* Allow set tax class as "parent"

* Removed duplicated sync

* Fixed wrong variation URLs

* Fixed undefined $image_id in WC_Product_Variation::get_image_id()

* Allow wc_rest_prepare_date_response() handle timestamps

* Updated get methods on REST API for variations

* Use variations CRUD to save variations metadata

* Remove deprecated get_variation_id()

* New default attributes method

* Fixed method returning in write context

* Allow set tax class as "parent"

* Removed duplicated sync

* Fixed coding standards

* TODO is not accurate.

* Should pass WC_Product instancies to WC_Comments methods (#12327)

* Use new method in abstract order class to prevent headers sent issue in tests

* Fixed variable description in REST API

* Updated how create initial product variation

* Fixed a few fatal errors and warnings in Products CRUD (#12329)

* Fixed a few fatal errors and warnings in Products CRUD

* Fixed sync functions

* Add variations CRUD to legacy API (#12331)

* Apply crud to variable products in legacy API v1

* New REST API do not need fallback for default attributes

* Apply variations CRUD to legacy API v2

* Legacy v2 - save default attributes

* Variations in legacy API v2 do not have descriptions

* Fixed legacy API v2 variations params

* Applied variations CRUD to legacy API v3

* Sync before save in legacy apis

* Punc

* Removed API todos

* Removed test

* Products endpoint tweaks (#12354)

* Var type already normalized on CRUD

* Let Product CRUD handle with validation, sanitization and conditional checks

* Set downloads using WC_Product_Download

* Stop try catch exceptions more than one time

* Handle WC_Data_Exception in legacy API

* Complete remove products when fails on creating

* On creating I mean!

* Already have a method to complete delete products

* Fixed standards using WP CodeSniffer

* get_the_terms() returns false when empty

* get_manage_stock returns boolean

@claudiosanches

* Merge conflict

* Variations API endpoint fixes

* Product CRUD improvements (#12359)

* args is not used any more - remove todo

* Added test for attributes

* wc_get_price_excluding_tax usage

* parent usage

* Fix rating counts

* Test fixes

* Cleanup after tests

* Make sure status transition code runs even during API calls, not just in admin.

* Default visibility

* Fix attribute setting in API

* Use get name instead of get title

* variation id usage

* Improved cross sell templates

* variation_data

* Grouped product sync

* Notices

* Sync is not needed in API

* Delete

* Rename interfaces

* Update counts in data store
2016-11-16 12:38:24 +00:00
Zachary 09f53ce778 Add counties for Republic of Ireland, change Postcode label to Eircode (#12180) 2016-11-03 11:48:14 +00:00
Rami Yushuvaev 4375618438 i18n context functions (#12156)
* Replace some context function with translation comments

* Remove two more context function

* Replace another context function with translation comments
2016-10-24 08:31:07 +01:00
Claudio Sanches 657c312cae Fix strings case (#12069)
* Fixed case for all _e, esc_attr_e and esc_html_e strings

* Fixed case for all _n_noop strings

* Fixed case for all _x strings

* Fixed case for all __, esc_html__ and esc_attr__ strings

* Fixed a few more strings

* Fixed strings in unit tests

* Fix PayPal Standard case.

* Save Order text
2016-10-12 11:16:30 +01:00
Mike Jolley 9aea350628 Merge branch 'pr/11906' 2016-10-11 17:51:45 +01:00
Matty ae75f8b8cd Adjusts all references of 'woothemes' to 'woocommerce' in relevant URLs, excluding the Travis CI integration which correctly uses 'woocommerce/woocommerce'. 2016-09-28 12:17:40 +02:00
corsonr b3236b4088 Add autofocus support 2016-09-12 21:33:52 +02:00
Aristeides Stathopoulos 734f284fa4 WordPress.PHP.YodaConditions.NotYoda 2016-09-08 01:32:24 +03:00
Aristeides Stathopoulos d4e3faf014 PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket 2016-09-02 04:51:31 +03:00
Aristeides Stathopoulos 82f3cc221e WordPress.WhiteSpace.ControlStructureSpacing.NoSpaceBeforeOpenParenthesis 2016-08-27 07:23:02 +03:00
Aristeides Stathopoulos 730069db06 WordPress.Arrays.ArrayDeclaration.SpaceAfterKeyword 2016-08-27 05:39:16 +03:00
Aristeides Stathopoulos b063bcfe4c last item in a multiline-array should end in a comma 2016-08-27 04:46:45 +03:00
JLuis Freitas 5a0f0cf5b4 add PT (Portugal) address format
add $postcode_before_city format to portuguese addresses
2016-08-16 17:10:09 +01:00
Mike Jolley 730019ef18 scrutinizer best practice 2016-06-06 19:39:23 +01:00
Scrutinizer Auto-Fixer 7cef8ae4c9 Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2016-06-06 16:50:18 +00:00
kreamweb 0a2c0af5ff Add check of $raw_countries before the foreach in WC_Countries 2016-05-14 11:02:05 +02:00
Matheus Lopes f0c26b7439 Refatoring main code 2016-04-28 13:37:30 -03:00
Matheus Lopes 2c191f5bb7 Enable countries exceptions to Billing and Shipping 2016-04-20 14:55:05 -03:00
Mike Jolley 3112c76939 Made postcode non required for ireland
Closes #10663
2016-04-18 11:41:24 +01:00
Caleb Burks c11c0cb51b Add NZ locale labels 2016-04-12 22:39:04 -05:00
Mike Jolley ac122f13b9 Add context to checkout error messages
Closes #10540
2016-03-14 11:54:16 +00:00
Mike Jolley 352184cc06 Merge branch 'master' into shipping-zones
# Conflicts:
#	assets/css/admin.css
#	i18n/languages/woocommerce.pot
#	includes/abstracts/abstract-wc-payment-gateway.php
#	includes/abstracts/abstract-wc-shipping-method.php
#	includes/admin/settings/class-wc-settings-shipping.php
#	includes/wc-core-functions.php
#	uninstall.php
2016-02-05 14:58:48 +00:00
Mike Jolley 8d0591d7c6 [2.5] Prevent notice in get_allowed_countries 2016-02-01 12:04:34 +00:00
Mike Jolley a2fbfec5bf [2.5] Show user country rather than base country in "estimated for" messages
#10148
2016-01-25 10:16:39 +00:00
Jon Koops 7e750716e3 Added autocomplete attributes for checkout fields
This allows browsers to automatically fill in the appropriate fields
for the checkout process. This should significantly improve the
checkout experience for a lot of users, especially those that
frequently shop online in different shops.

The following fields now have proper autocomplete attributes:
 - First name
 - Last name
 - Company name
 - County
 - Address line 1 (Street name)
 - Address line 2 (Apartment, suite, unit etc.)
 - City
 - State / Country
 - Postcode / ZIP
 - Email address
 - Phone number

For more information about how autocomplete can improve user
experience: https://developers.google.com/web/updates/2015/06/checkout-faster-with-a
utofill
A complete overview can be found in the WHATWGHTML specification: https://html.spec.whatwg.org/multipage/forms.html#autofill
2016-01-11 22:55:38 +01:00
Mike Jolley 1076854608 Merge branch 'master' into shipping-zones
# Conflicts:
#	assets/css/admin.css
#	includes/abstracts/abstract-wc-shipping-method.php
#	includes/class-wc-shipping.php
#	includes/shipping/flat-rate/class-wc-shipping-flat-rate.php
#	includes/shipping/flat-rate/includes/class-wc-eval-math.php
#	includes/shipping/free-shipping/class-wc-shipping-free-shipping.php
#
includes/shipping/legacy-international-delivery/class-wc-shipping-legacy
-international-delivery.php
#
includes/shipping/legacy-local-delivery/class-wc-shipping-legacy-local-d
elivery.php
2016-01-11 11:48:18 +00:00
Fredrik Forsmo 0f0d40ceff Improve docblock comments WC_Countries class
* Added comment to `get_allowed_country_states` and
`get_shipping_country_states`
* Added missing param tags to `country_dropdown_options`
* Fixed param tag for `trim_formatted_address_line`
2016-01-06 15:51:58 +01:00
Mike Jolley ea84096b69 Remove inconsistent usage of placeholders
State field has no placeholder, yet some fields had a duplicate of the
label. This removes those placeholders so all fields remain consistent.
cc @claudiosmweb @jameskoster Also removes commented out code.
2016-01-06 12:22:01 +00:00
Mike Jolley a0e0bb1e55 Load instance methods for calculations 2015-12-15 15:00:45 +00:00
Mike Jolley 091a8a7641 Zone matching functions 2015-12-15 12:39:52 +00:00
Mike Jolley 485a127778 get_continents 2015-12-08 11:15:02 +00:00
Coen Jacobs bae582e3ff End function requires variable to prevent strict standards errors
Just a temporary variable that is only used to pass an actual variable
to the PHP end function (as that takes a reference as argument). This
prevents strict standard errors.
2015-12-07 08:10:19 +01:00
roykho 9078e30ea4 Fix acronym zip to be all capitals fixes #9641 2015-11-18 15:32:23 -08:00
Mike Jolley aeb48e35a7 [2.4] Removes Switzerland from VAT definition
Confirmed outside of EU and not applicable to things such as EU VAT
@hussong
2015-11-16 16:00:51 +00:00
Maxwell Morgan da6eeebf81 Update class-wc-countries.php
Typo on ether -> either
2015-11-10 11:51:26 -05:00
Nicola Mustone c9da4f928a check if ABSPATH is defined 2015-11-06 10:22:19 +01:00
Shiva Poudel 8300192bf7 Zone and postal code updated 2015-11-05 23:25:30 +05:45
Shiva Poudel a1550fab77 Updated Nepal local settings 2015-11-05 23:06:15 +05:45
Claudio Sanches 5893875b0c Removed period for file headers 2015-11-03 11:53:50 -02:00
Claudio Sanches ee30b5b308 Fixed php docs standards 2015-11-03 11:31:20 -02:00
Mike Jolley 66c0d8f009 Swiss
Fixes #9001
2015-09-01 13:50:14 +01:00
Claudio Sanches d976cd8340 Disabled states for AX, closes #8594 2015-07-17 16:29:21 -03:00
Claudio Sanches 9e41552342 Removed all "@return void" 2015-07-16 16:55:48 -03:00
Mike Jolley 9843608cd4 Move country field with other address fields
Closes #8263
2015-06-17 10:17:41 +01:00
James Koster 56b1699e14 placeholder. closes #7885 2015-04-09 15:17:59 +01:00
James Koster 944723d7ac tel input #7827 2015-04-01 17:36:58 +01:00
James Koster 33a3940501 email input 2015-03-27 11:49:36 +00:00
Mike Jolley a017ebfff2 [2.3] Chile address format
Closes #7754
2015-03-18 11:35:20 +00:00
James Koster 90a78780be state placeholders. closes #7729 2015-03-16 12:56:22 +00:00
Mike Jolley 66e6366be0 Shipping calculator - Made state/postcode respect country locale like checkout.
Fixes #7637
2015-03-06 12:37:21 +00:00
Claudio Sanches 25944c9086 Fixed the WC_Countries::get_formatted_address() default args
@mikejolley
2015-03-06 00:05:40 -03:00
Mike Jolley 4d8d4310bf Tidyup #7627 2015-03-05 09:20:24 +00:00
Rasmus 13f6e442df Fix missing fields in get_formatted_address
Fixes missing fields in get_formatted_address in WC_Countries so it doesn't throw a notice about undefined variable when argument is missing.
2015-03-04 15:02:35 +01:00
shivapoudel 16047b7808 Added Nepal(NP) country locale used by the checkout 2015-01-19 00:45:19 +05:45
shivapoudel 5ce1e1e8a6 Refactor WC_Countries Class 2015-01-19 00:44:17 +05:45
Bryce f3328ac601 Shows VN postcode field and moves before city
Closes #7094
2015-01-13 10:18:48 +07:00
Hector Tolmo 6f4f289c7e Update class-wc-countries.php
State = Region validate Chile line 667 and postcode null
2015-01-06 22:24:23 -03:00
Mike Jolley 6e5ec55374 Option for get_european_union_countries() to return eu_vat countries 2015-01-05 17:29:01 +00:00
Mike Jolley f847b92a0f Merge branch 'wc-geolocation' 2015-01-05 10:18:25 +00:00
Mike Jolley 395107fc72 MC (monaco) and IM (isle of man, part of UK) also use VAT.
Closes #7013
2015-01-03 16:48:29 +00:00
Mike Jolley 6800ee0ec3 Base vs default 2014-12-23 17:34:05 +00:00
Mike Jolley e6b94e486b Leave postcode before city swapping to JS
Fixes #6842
2014-12-09 09:07:28 +00:00
Bryce 3fd7997413 Move locale to new method in BACS gateway 2014-11-24 21:26:33 +07:00
Bryce 7abd1358fc Fix whitespace 2014-11-21 16:13:03 +07:00
Bryce 6dad8fdc59 #6026 - Introduction of Sort Code 'locale' for BACS
In the admin, it will use the store’s base country to determine the
term for ‘Sort Code’.

In the front-end, it will use the customer’s billing country to
determine the term for ‘Sort Code’.

In all cases, if a locale does not have a sortcode label set, it will
use ‘Sort Code’.

**Locales have been added for:**
* AU
* CA
* IE
* IN
* IT
* NZ
* SE
* US
* GB
* ZA

But may need adjusting based on user feedback.
2014-11-21 16:10:12 +07:00
claudiosmweb 8eeb6fc204 Removed more some unused code 2014-11-19 22:43:09 -02:00
Mike Jolley 3ccd54f268 English version of Taiwan address format
Closes #6651
2014-11-12 15:28:33 +00:00
Vachan Kudmule 755d065107 Added Address Format for India
In India the Postcode is at the city level, thus updated the file in accordance with the Indian Standard of Address Formatting.
@line#382: Hyphenated Postcode to the City Name & State then Country.
REF: 
1) I am an Indian Citizen myself
2) http://en.wikipedia.org/wiki/Address_(geography)#India
3) http://www.addressdoctor.com/en/countries-data/address-formats.html#fbid=Bv4FMyXjoPh
4) http://www.bitboost.com/ref/international-address-formats/india/
2014-10-27 18:12:51 +05:30
Mike Jolley d68cab0eec In the US address format, use state code rather than the full state name. 2014-10-13 18:28:38 +01:00
Mike Jolley 229d9135ef Prevent errors when country field is disabled
Fixes #6336
2014-09-22 13:23:31 +01:00
Mike Jolley 509c10f7e5 Removed postcode for Bahamas.
Fixes #6223
2014-09-11 14:26:22 +01:00
Mike Jolley c4ef86d44e scrutinizer patches 2014-09-08 00:37:55 +01:00
James Collins 1288a45eeb Add Australian checkout locale
Town / City -> Suburb
State / Country -> State
Postcode / Zip -> Postcode
2014-08-14 12:07:41 +08:00
Shohei Tanaka 7c10c4442e Correct the order of Japanese address fields
The order was incorrect. Changing the order of the input address field.
2014-07-01 16:52:45 +09:00
Shohei Tanaka 19b5d8073e Update class-wc-countries.php for Japanese State
I don't use the word of Province for the largest administrative divisions of Japan, like the state in USA.
Sometimes I use the word of State for 都道府県. But I search some site, It seems to say that "Prefecture"
 is formally. Perhaps Prefecture is best.

Please check following site.
1. One of Most Popular Japanese to English dictionary site:
http://ejje.weblio.jp/content/%E9%83%BD%E9%81%93%E5%BA%9C%E7%9C%8C

2. Official Japanese law Translation site(Please click 都道府県)
http://www.japaneselawtranslation.go.jp/dict/list?re=02&ft=1&dn=1&ky=%E9%83%BD%E9%81%93%E5%BA%9C%E7%9C%8C&x=63&y=8&co=1
2014-06-24 19:00:03 +09:00
Mike Jolley 098a6afbbf Fix state display Closes #5587 2014-05-30 13:33:09 +01:00
Mike Jolley d88425f47e Load countries and states when needed rather than in the constructor. Closes #4158 2014-05-28 16:48:21 +01:00
Mike Jolley e198ee517a Made stateless classes static to allow unhooking of hooks
Closes #5151
2014-05-28 14:52:50 +01:00
Mike Jolley 1ed0938581 [2.2] Log changes Closes #4926
Added WC_LOG_DIR constant
Added log viewer
Changed default logging directory to 1 up from ABSPATH inside wc-logs
2014-05-28 11:12:38 +01:00
Y12STUDIO a6fc9920d7 Update the address format for Taiwan 2014-05-19 16:08:30 +08:00
Mike Jolley 18294e715d Trim commas and empty lines off address formats Fixes #5411 2014-05-06 16:04:11 +01:00
Md Ariful Haque Khan 6c028259ee Bangladeshi states (districts) list add and state label rename. 2014-03-21 23:26:13 +06:00
Patrick Rauland f78482dd6e returning false instead of array for countries without states 2014-03-03 16:04:00 -08:00
tamarazuk 510e46963a Add Canadian address format
.. as per Canada Post's addressing guidelines: http://www.canadapost.ca/tools/pg/manual/PGaddress-e.asp#1413985
2014-02-26 15:50:58 -05:00
Paolo Albera 394e743dbd Update class-wc-countries.php 2014-02-13 13:12:47 +01:00
Shohei Tanaka 72189fd0d4 Correct get_country_locale for Japanese
Change and correct for the plug-in introduction to Japanese environment.
2014-01-04 06:46:00 +09:00
Shohei Tanaka e6271e425d correct the state field setting of Japan.
States file of JP.php has existed. So please delete this line.
2014-01-01 06:37:23 +09:00
Shohei Tanaka ea3834cdcc correct address_formats in Japan
in Japan ,the name order is last (family) name to first name.
2013-12-31 06:35:21 +09:00
Coen Jacobs 61a783886d Suggested code changes in #4266 2013-12-03 15:03:25 +01:00
Gregory K f937c36250 Inconsistent return types: TODOs 2013-12-03 14:53:49 +01:00
Mike Jolley af34b43ee6 Tweaks for #4239 2013-12-03 12:14:12 +00:00
Ewout Fernhout bfa4ce53ff Allow custom checkout fields to be localized 2013-11-28 15:46:08 +01:00
Mike Jolley 3da2afdcef Isset rather than empty, so states work when allowed countries are set. Closes #4223 2013-11-27 15:38:52 +00:00
Coen Jacobs 19688ad9ef Fixed several @return void clauses. There are more. No code changes in this commit, only PhpDocs
Closes #4216
2013-11-27 10:03:47 +01:00
Patrick Rauland 9ac8b406c5 removing postcode for Bolivia 2013-11-26 15:41:54 -06:00
Coen Jacobs 4afbd0b556 Merge branch 'function-call-refactor'
Conflicts:
	includes/admin/post-types/meta-boxes/class-wc-meta-box-order-data.php
	includes/shortcodes/class-wc-shortcode-cart.php
	includes/wc-template-functions.php
2013-11-25 15:42:26 +01:00