Changeset 3417686
- Timestamp:
- 12/11/2025 07:10:46 PM (4 months ago)
- Location:
- portugal-states-distritos-for-woocommerce/trunk
- Files:
-
- 2 edited
-
readme.txt (modified) (9 diffs)
-
woocommerce-portugal-states.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
portugal-states-distritos-for-woocommerce/trunk/readme.txt
r3390566 r3417686 5 5 Tested up to: 6.9 6 6 Requires PHP: 7.2 7 Stable tag: 4. 17 Stable tag: 4.2 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0.html 10 10 11 This plugin adds the Portuguese "States", known as "Distritos", to WooCommerce and sets the correct address format for Portugal.11 This plugin adds the Portuguese “States”, known as “Distritos”, to WooCommerce and sets the correct address format for Portugal. 12 12 13 13 == Description == 14 14 15 This plugin adds the 18 Portuguese "States" (known as "Distritos") plus the 2 Autonomous Regions (known as "Regiões Autónomas", Madeira and Açores) to WooCommerce.16 17 Also sets the right name for "Districts" and the correct "Postcode"/"City"order and the correct address format for Portugal.15 This plugin adds the 18 Portuguese “States” (known as “Distritos”) plus the 2 Autonomous Regions (known as “Regiões Autónomas”, Madeira and Açores) to WooCommerce. 16 17 Also sets the right name for “Districts” and the correct “Postcode”/“City” order and the correct address format for Portugal. 18 18 19 19 And... that’s pretty much it. … … 23 23 = Features: = 24 24 25 * Adds the Portuguese "States", known as "Distritos", to WooCommerce26 * Sets the correct address format for Portugal, including the correct "Postal Code"/"City"positioning on the checkout25 * Adds the Portuguese “States”, known as “Distritos”, to WooCommerce 26 * Sets the correct address format for Portugal, including the correct “Postal Code”/“City” positioning on the checkout 27 27 28 28 = Do your customers still write the full address details manually on the checkout? = … … 53 53 == Installation == 54 54 55 Use the included automatic install feature on your WordPress admin panel and search for "Portugal States (Distritos) for WooCommerce".55 Use the included automatic install feature on your WordPress admin panel and search for “Portugal States (Distritos) for WooCommerce”. 56 56 57 57 == Frequently Asked Questions == … … 75 75 Yes. 76 76 77 = Is this plugin with Express Checkout, like Apple Pay? = 78 79 We’re not sure exactly when, but Apple stopped requesting the "Distrito" field in Apple Pay addresses, which causes checkout to fail if you set your shipping zones to "Distritos". 80 So, if you’re using Apple Pay (maybe Google Pay as well), we recommend you set your shipping zones with postcode intervals; for example, one zone for Portugal, restricted to postcodes 0000000...8999999, and another for the islands, restricted to 9000000...9999999. 81 82 Or you can use Apple Pay and Google Pay via the [ifthenpay gateway with our plugin](https://wordpress.org/plugins/multibanco-ifthen-software-gateway-for-woocommerce/), where the address is not fetched from Apple but from the WooCommerce checkout. 77 = Is this plugin compatible with Express Checkout, like Apple and Google Pay? = 78 79 Apple and Google are not requesting the “Distrito” field in Apple Pay addresses, which causes checkout to fail if you set your shipping zones with “Distritos”. 80 So, if you’re using these methods, we recommend you set your shipping zones with postcode intervals; for example, one zone for Portugal, restricted to postcodes 0000000...8999999, and another for the islands, restricted to 9000000...9999999. 81 You can keep using this plugin, but the shipping zones should be set with postcodes. 82 83 Alternatively, version 7.0 of our “[Portuguese Postcodes for WooCommerce](https://nakedcatplugins.com/product/portuguese-postcodes-for-woocommerce-technical-support/)” plugin, alongside “WooCommerce Stripe Payment Gateway” version 10.2.0 or above, fixes this. 84 85 Or you can use Apple Pay and Google Pay via the [ifthenpay gateway with our plugin](https://wordpress.org/plugins/multibanco-ifthen-software-gateway-for-woocommerce/), which fetches the address from the WooCommerce checkout. 83 86 84 87 = I need help, can I get technical support? = … … 96 99 == Changelog == 97 100 101 = 4.2 - 2025-12-11 = 102 * [TWEAK] Add information to the readme file regarding instant payment methods not requesting “Distrito” for Portuguese addresses, and the fix available by using [Portuguese Postcodes for WooCommerce](https://nakedcatplugins.com/product/portuguese-postcodes-for-woocommerce-technical-support/) 103 * [DEV] Tested with WordPress 7.0-alpha-61365 and WooCommerce 10.4.0 104 98 105 = 4.1 - 2025-10-05 = 99 * [TWEAK] Add information to the readme file regarding instant payment methods not requesting "Distrito"for Portuguese addresses106 * [TWEAK] Add information to the readme file regarding instant payment methods not requesting “Distrito” for Portuguese addresses 100 107 * [DEV] Tested up to WordPress 6.9-beta2-61099 and WooCommerce 10.3.4 101 108 102 109 = 4.0 - 2025-06-24 = 103 * [TWEAK] Improve the mechanism to keep the "Portuguese Postcodes for WooCommerce"admin notice from showing to the same user in the next 120 days after dismissal110 * [TWEAK] Improve the mechanism to keep the “Portuguese Postcodes for WooCommerce” admin notice from showing to the same user in the next 120 days after dismissal 104 111 * [DEV] Tested up to WordPress 6.9-alpha-60342 and WooCommerce 10.0.0-rc.1 105 112 … … 157 164 * Complete code refactoring 158 165 * Show Postcode and Postcode City side by side on the checkout and added two new filters to change it: `woocommerce_portugal_postcode_class` and `woocommerce_portugal_city_class` 159 * Changed the (english) city label from "Postcode Town / City" to "Postcode City"(no changes in Portuguese)166 * Changed the (english) city label from “Postcode Town / City” to “Postcode City” (no changes in Portuguese) 160 167 * Added support information to the Frequently Asked Questions readme section 161 168 * Requires WooCommerce 3.0 … … 203 210 204 211 = 2.1.1 = 205 * Added the `woocommerce_portugal_postcode_priority` filter to allow overriding the "Postal Code"priority value212 * Added the `woocommerce_portugal_postcode_priority` filter to allow overriding the “Postal Code” priority value 206 213 207 214 = 2.1 = 208 * Fix "Postal Code"/"City"fields order on the checkout on newer WooCommerce versions209 * The "City" field label is now "Postcode Town / City"on the checkout210 * New `woocommerce_portugal_city_label` filter to be able to change the "City"field label211 * New `woocommerce_portugal_state_label` filter to be able to change the "District"field label212 * New `woocommerce_portugal_state_required` filter to be able to set the "District"field as not required215 * Fix “Postal Code”/“City” fields order on the checkout on newer WooCommerce versions 216 * The “City” field label is now “Postcode Town / City” on the checkout 217 * New `woocommerce_portugal_city_label` filter to be able to change the “City” field label 218 * New `woocommerce_portugal_state_label` filter to be able to change the “District” field label 219 * New `woocommerce_portugal_state_required` filter to be able to set the “District” field as not required 213 220 * Bumped `WC tested up to` tag 214 221 215 222 = 2.0 = 216 * Removed the district from the plain text address format for Portugal, as we do not use it on a day to day basis: "{name}\n{company}\n{address_1}\n{address_2}\n{postcode} {city}\n{country}"(can be restored via the `woocommerce_portugal_address_format_include_state` filter)223 * Removed the district from the plain text address format for Portugal, as we do not use it on a day to day basis: “{name}\n{company}\n{address_1}\n{address_2}\n{postcode} {city}\n{country}” (can be restored via the `woocommerce_portugal_address_format_include_state` filter) 217 224 * Better coding standards 218 225 … … 239 246 240 247 = 1.5 = 241 * Sets the correct Portuguese address format: "{name}\n{company}\n{address_1}\n{address_2}\n{postcode} {city}\n{state}\n{country}"248 * Sets the correct Portuguese address format: “{name}\n{company}\n{address_1}\n{address_2}\n{postcode} {city}\n{state}\n{country}” 242 249 243 250 = 1.4.1 = 244 * Bumped "Requires at least" and "Tested up to"tags251 * Bumped “Requires at least” and “Tested up to” tags 245 252 246 253 = 1.4 = … … 254 261 255 262 = 1.1 = 256 * Now also sets the right name for "Districts" and the correct "Postal Code"/"City"order263 * Now also sets the right name for “Districts” and the correct “Postal Code”/“City” order 257 264 258 265 = 1.0 = -
portugal-states-distritos-for-woocommerce/trunk/woocommerce-portugal-states.php
r3390566 r3417686 1 1 <?php 2 /* 2 /** 3 3 * Plugin Name: Portugal States (Distritos) for WooCommerce 4 4 * Plugin URI: https://www.webdados.pt/wordpress/plugins/portugal-states-distritos-woocommerce-wordpress/ 5 5 * Description: This plugin adds the Portuguese "States", known as "Distritos", to WooCommerce and sets the correct address format for Portugal 6 * Version: 4. 16 * Version: 4.2 7 7 * Author: Naked Cat Plugins (by Webdados) 8 8 * Author URI: https://nakedcatplugins.com … … 12 12 * Requires PHP: 7.2 13 13 * WC requires at least: 7.1 14 * WC tested up to: 10. 314 * WC tested up to: 10.4 15 15 * Requires Plugins: woocommerce 16 16 * License: GPLv3 17 */17 */ 18 18 19 19 /* WooCommerce CRUD not needed */ … … 25 25 26 26 /* Init */ 27 add_action( 'plugins_loaded', 'woocommerce_portugal_states_init' );28 27 function woocommerce_portugal_states_init() { 29 28 if ( class_exists( 'WooCommerce' ) && defined( 'WC_VERSION' ) && version_compare( WC_VERSION, '7.1', '>=' ) ) { … … 34 33 } 35 34 } 35 add_action( 'plugins_loaded', 'woocommerce_portugal_states_init' ); 36 36 37 37
Note: See TracChangeset
for help on using the changeset viewer.