Show shipping methods by map location
-
I’m currently working on a website for a client that uses Multi-Step Checkout Pro and Order Delivery Date along with Woocommerce. One of the reasons they reached to us was that they needed to add a map on the Order Review step, in which the user would select their location, and based on that point in the map, assign them a shipping zone.
I’ve created a Polygons table on the database with the coordinates (defining the shipping zone) and a zone id. There’s a field with a Google map on the admin page for editing or creating the polygon for each zone.
So far I’ve come across two major problems:
- Modifying the checkout fields
Whenever I try to insert content on the page using Woocomerce’s hooks or templates, the content gets rendered either on top or the bottom of the page.Inserted content re-renders
On top of that, they’re using Order Delivery Date for creating delivery schedules, based on each method. I think this is making everything re-render, but my content gets added again every time it does. - Setting the zone dynamically
I’m also having trouble trying to set the shipping zone programmatically, to show only the shipping methods I need, so the rest of the checkout process can continue with the method the user chose.
I don’t know if these are either issues concerning the plugins or my understanding of Woocomerce. Anyhow, any type of help would be extremely appreciated, since I’m stuck in this part of the project.
Thanks!
- This topic was modified 2 years, 11 months ago by facumidvetkin.
The page I need help with: [log in to see the link]
- Modifying the checkout fields
-
As you are using third party plugins Multi-Step Checkout Pro and Order Delivery Date, you can get the best support by reaching out to the support teams of these plugins, as we do not support third-party plugins on these forums.
If you still need help with this, we suggest hiring a developer or one of the customization experts listed at https://woocommerce.com/customizations/.
Kindly note that this particular forum is for questions that are directly related to the features and functionality of the free WooCommerce plugin. While we’re experts on our own products, third-party plugins are best supported by their own developers.
Thanks for the immediate response, Margaret.
I already contacted the developers of those two plugins, and both of them replied saying that this is a matter concerning WooCommerce, and that their plugins don’t interfere with what I’m trying to do. That’s the reason I ended up here.
Thanks for letting us know about this.
In order for us to get a better idea of your setup, could you please share a copy of your site’s System Status?
You can find it via WooCommerce > Status. Select “Get system report” and then “Copy for support”. Once you’ve done that, paste it here in your response.
### WordPress Environment ### WordPress address (URL): https://sucan.uy Site address (URL): https://sucan.uy WC Version: 5.8.0 REST API Version: ? 5.8.0 WC Blocks Version: ? 5.9.1 Action Scheduler Version: ? 3.3.0 WC Admin Version: ? 2.7.2 Log Directory Writable: ? WP Version: 5.8.2 WP Multisite: – WP Memory Limit: 512 MB WP Debug Mode: – WP Cron: ? Language: es_ES External object cache: – ### Server Environment ### Server Info: Apache PHP Version: 7.3.17 PHP Post Max Size: 40 MB PHP Time Limit: 6000 PHP Max Input Vars: 1000 cURL Version: 7.69.0 OpenSSL/1.1.1d SUHOSIN Installed: – MySQL Version: 8.0.18 Max Upload Size: 40 MB Default Timezone is UTC: ? fsockopen/cURL: ? SoapClient: ? DOMDocument: ? GZip: ? Multibyte String: ? Remote Post: ? Remote Get: ? ### Database ### WC Database Version: 5.8.0 WC Database Prefix: wp_ Tama?o total de la base de datos: 976.86MB Tama?o de los datos de la base de datos: 814.24MB Tama?o del índice de la base de datos: 162.62MB wp_woocommerce_sessions: Datos: 34.17MB + índice: 1.28MB + Motor MyISAM wp_woocommerce_api_keys: Datos: 0.00MB + índice: 0.01MB + Motor MyISAM wp_woocommerce_attribute_taxonomies: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_downloadable_product_permissions: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_order_items: Datos: 3.02MB + índice: 1.50MB + Motor MyISAM wp_woocommerce_order_itemmeta: Datos: 18.56MB + índice: 11.86MB + Motor MyISAM wp_woocommerce_tax_rates: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_tax_rate_locations: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_shipping_zones: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_shipping_zone_locations: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_shipping_zone_methods: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_payment_tokens: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_payment_tokenmeta: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woocommerce_log: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_actionscheduler_actions: Datos: 3.68MB + índice: 1.99MB + Motor MyISAM wp_actionscheduler_claims: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_actionscheduler_groups: Datos: 0.00MB + índice: 0.01MB + Motor MyISAM wp_actionscheduler_logs: Datos: 2.92MB + índice: 2.10MB + Motor MyISAM wp_as3cf_items: Datos: 2.52MB + índice: 4.27MB + Motor InnoDB wp_berocket_termmeta: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_braapf_product_stock_status_parent: Datos: 0.11MB + índice: 0.06MB + Motor InnoDB wp_braapf_product_variation_attributes: Datos: 0.11MB + índice: 0.19MB + Motor InnoDB wp_braapf_term_taxonomy_hierarchical: Datos: 0.06MB + índice: 0.14MB + Motor InnoDB wp_braapf_variation_attributes: Datos: 0.02MB + índice: 0.03MB + Motor InnoDB wp_cf_form_entries: Datos: 0.02MB + índice: 0.06MB + Motor InnoDB wp_cf_form_entry_meta: Datos: 0.02MB + índice: 0.03MB + Motor InnoDB wp_cf_form_entry_values: Datos: 0.02MB + índice: 0.05MB + Motor InnoDB wp_cf_forms: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_cf_pro_messages: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_cf_queue_failures: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_cf_queue_jobs: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_commentmeta: Datos: 0.04MB + índice: 0.05MB + Motor MyISAM wp_comments: Datos: 8.40MB + índice: 3.52MB + Motor MyISAM wp_et_bloom_stats: Datos: 1.71MB + índice: 0.38MB + Motor MyISAM wp_failed_jobs: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_links: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_litespeed_img_optm: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_litespeed_url: Datos: 0.02MB + índice: 0.03MB + Motor InnoDB wp_litespeed_url_file: Datos: 0.02MB + índice: 0.05MB + Motor InnoDB wp_mail_bank: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_mail_bank_logs: Datos: 412.64MB + índice: 0.37MB + Motor MyISAM wp_mail_bank_meta: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_mailchimp_carts: Datos: 0.40MB + índice: 0.03MB + Motor MyISAM wp_mailchimp_jobs: Datos: 2.16MB + índice: 0.07MB + Motor MyISAM wp_ml_attributes_map_table: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_ml_categories_map_table: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_ml_categories_table: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_ml_import_table: Datos: 2.52MB + índice: 0.02MB + Motor InnoDB wp_ml_product_variations_map_table: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_options: Datos: 139.66MB + índice: 45.69MB + Motor MyISAM wp_postmeta: Datos: 88.77MB + índice: 41.20MB + Motor MyISAM wp_posts: Datos: 18.19MB + índice: 2.70MB + Motor MyISAM wp_queue: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_redirection_404: Datos: 21.29MB + índice: 3.05MB + Motor MyISAM wp_redirection_groups: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_redirection_items: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_redirection_logs: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_sbi_instagram_feed_locator: Datos: 0.02MB + índice: 0.03MB + Motor InnoDB wp_sbi_instagram_feeds_posts: Datos: 0.02MB + índice: 0.03MB + Motor InnoDB wp_sbi_instagram_posts: Datos: 0.13MB + índice: 0.00MB + Motor InnoDB wp_term_relationships: Datos: 0.24MB + índice: 0.54MB + Motor MyISAM wp_term_taxonomy: Datos: 0.02MB + índice: 0.03MB + Motor MyISAM wp_termmeta: Datos: 0.11MB + índice: 0.08MB + Motor MyISAM wp_terms: Datos: 0.02MB + índice: 0.04MB + Motor MyISAM wp_usermeta: Datos: 11.57MB + índice: 7.33MB + Motor MyISAM wp_users: Datos: 0.56MB + índice: 0.57MB + Motor MyISAM wp_wc_admin_note_actions: Datos: 0.01MB + índice: 0.00MB + Motor MyISAM wp_wc_admin_notes: Datos: 0.03MB + índice: 0.00MB + Motor MyISAM wp_wc_category_lookup: Datos: 0.01MB + índice: 0.01MB + Motor MyISAM wp_wc_customer_lookup: Datos: 0.62MB + índice: 0.47MB + Motor MyISAM wp_wc_download_log: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wc_order_coupon_lookup: Datos: 0.04MB + índice: 0.07MB + Motor MyISAM wp_wc_order_product_lookup: Datos: 2.56MB + índice: 2.44MB + Motor MyISAM wp_wc_order_stats: Datos: 1.17MB + índice: 0.81MB + Motor MyISAM wp_wc_order_tax_lookup: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wc_product_meta_lookup: Datos: 0.16MB + índice: 0.21MB + Motor MyISAM wp_wc_reserved_stock: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wc_tax_rate_classes: Datos: 0.00MB + índice: 0.01MB + Motor MyISAM wp_wc_webhooks: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfblockediplog: Datos: 0.33MB + índice: 0.22MB + Motor MyISAM wp_wfblocks7: Datos: 0.11MB + índice: 0.06MB + Motor MyISAM wp_wfconfig: Datos: 3.14MB + índice: 0.02MB + Motor MyISAM wp_wfcrawlers: Datos: 0.01MB + índice: 0.00MB + Motor MyISAM wp_wffilechanges: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wffilemods: Datos: 4.15MB + índice: 0.80MB + Motor MyISAM wp_wfhits: Datos: 1.41MB + índice: 0.14MB + Motor MyISAM wp_wfhoover: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfissues: Datos: 0.05MB + índice: 0.01MB + Motor MyISAM wp_wfknownfilelist: Datos: 2.27MB + índice: 0.25MB + Motor MyISAM wp_wflivetraffichuman: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wflocs: Datos: 0.01MB + índice: 0.00MB + Motor MyISAM wp_wflogins: Datos: 0.49MB + índice: 0.10MB + Motor MyISAM wp_wfls_2fa_secrets: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wfls_settings: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wfnotifications: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfpendingissues: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfreversecache: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfsnipcache: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wfstatus: Datos: 0.17MB + índice: 0.06MB + Motor MyISAM wp_wftrafficrates: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_wm_blacklist: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wm_ext_qanda: Datos: 0.39MB + índice: 0.02MB + Motor InnoDB wp_wm_templatesync: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wm_templatesync_meta: Datos: 0.17MB + índice: 0.20MB + Motor InnoDB wp_woocommerce_sp_cards: Datos: 0.19MB + índice: 0.00MB + Motor InnoDB wp_woocommerce_sp_customers: Datos: 0.08MB + índice: 0.00MB + Motor InnoDB wp_woof_query_cache: Datos: 0.00MB + índice: 0.00MB + Motor MyISAM wp_woosync_mapping_attributes: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_woosync_mapping_categories: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_woosync_mapping_category_settings: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_woosync_mapping_profiles: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wpfm_backup: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wps_hit: Datos: 0.02MB + índice: 0.14MB + Motor InnoDB wp_wps_index: Datos: 10.50MB + índice: 18.48MB + Motor InnoDB wp_wps_key: Datos: 0.38MB + índice: 0.36MB + Motor InnoDB wp_wps_object_term: Datos: 1.52MB + índice: 2.28MB + Motor InnoDB wp_wps_object_type: Datos: 0.02MB + índice: 0.08MB + Motor InnoDB wp_wps_query: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wps_uri: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wps_user_agent: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_wt_iew_action_history: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wt_iew_cron: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wt_iew_ftp: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_wt_iew_mapping_template: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB wp_yith_wcan_filter_sessions: Datos: 0.02MB + índice: 0.05MB + Motor InnoDB wp_yoast_indexable: Datos: 8.52MB + índice: 5.16MB + Motor InnoDB wp_yoast_indexable_hierarchy: Datos: 1.17MB + índice: 0.47MB + Motor InnoDB wp_yoast_migrations: Datos: 0.02MB + índice: 0.02MB + Motor InnoDB wp_yoast_primary_term: Datos: 0.08MB + índice: 0.06MB + Motor InnoDB wp_yoast_seo_links: Datos: 0.14MB + índice: 0.09MB + Motor InnoDB wp_yoast_seo_meta: Datos: 0.02MB + índice: 0.00MB + Motor InnoDB ### Post Type Counts ### aoc_popup: 1 attachment: 4852 br_filters_group: 2 br_product_filter: 9 custom_css: 3 et_body_layout: 4 et_pb_layout: 63 et_template: 5 et_theme_builder: 1 GOTMLS_quarantine: 6 nav_menu_item: 337 oembed_cache: 6 page: 78 post: 11 product: 1154 product_variation: 1033 revision: 1683 shop_coupon: 482 shop_order: 16705 wcps: 1 woocarousel: 1 woocarouselpro: 2 wplayouts-siteimport: 1 yith_wcan_preset: 1 ### Security ### Secure connection (HTTPS): ? Hide errors from visitors: ? ### Active Plugins (37) ### WooCommerce SiemprePago Gateway: por SiemprePago - Gonzalo Pigni - Bruno Suarez – 1.35 Address Autocomplete: por HighAddons – 1.0.3 WP Offload Media: por Delicious Brains – 2.5.6 Bloom: por Elegant Themes – 1.3.12 Caldera Forms: por Caldera Forms – 1.9.4 Join.chat: por Creame – 4.1.15 Divi Booster: por Dan Mossop – 3.6.6 Descargar Plugins y Temas desde el Escritorio: por WPFactory – 1.8.0 Facebook for WooCommerce: por Facebook – 2.6.5 WooCommerce PagosWeb Gateway: por PagosWeb – 1.6 Anti-Malware Security and Brute-Force Firewall: por Eli Scheetz – 4.20.72 Improved Variable Product Attributes for WooCommerce: por Mihajlovic Nenad – 4.0.6 Smash Balloon Instagram Feed: por Smash Balloon – 2.9.4 WooCommerce Load More Products: por BeRocket – 1.1.9.2 Loco Translate: por Tim Whitlock – 2.5.5 Mailchimp for WooCommerce: por Mailchimp – 2.5.3 Order Delivery Date Pro for WooCommerce: por Tyche Softwares – 9.25.0 Order / Coupon / Subscription Export Import Plugin for WooCommerce (BASIC): por WebToffee – 2.1.1 Popup Anything - A Marketing Popup: por WP OnlineSupport Essential Plugin – 2.0.4 Redirection: por John Godley – 5.1.3 Sold Out Badge for WooCommerce: por Charlie Etienne – 2.0.10 Sucan Pets: por Sunshift – 1.0 UpdraftPlus - Backup/Restore: por UpdraftPlus.Com DavidAnderson – 1.16.62 Use Any Font: por Dnesscarkey – 6.1.7 Advanced AJAX Product Filters for WooCommerce: por BeRocket – 1.5.5.3 WooCommerce Google Analytics Integration: por WooCommerce – 1.5.3 WooCommerce Product Carousel Slider Pro: por ADL Plugins – 3.0.2 WooCommerce: por Automattic – 5.8.0 (la actualización a la versión 5.9.0 está disponible) Woomelly: por IMMAGIT – 2.5.0 Wordfence Security: por Wordfence – 7.5.7 Yoast SEO: por Equipo Yoast – 17.4 Administrador de archivos WP: por mndpsingh287 – 7.1.2 WP Htaccess Editor: por WebFactory Ltd – 1.70 Mail Bank: por Tech Banker – 4.0.14 Multi-Step Checkout Pro for WooCommerce: por SilkyPress – 2.25 WP-PageNavi: por Lester 'GaMerZ' Chan – 2.94.0 YITH WooCommerce Ajax Product Filter Premium: por YITH – 4.3.0 ### Inactive Plugins (15) ### Akismet Anti-Spam: por Automattic – 4.2.1 Breadcrumb NavXT: por John Havlik – 6.6.0 Divi Builder: por Elegant Themes – 4.11.3 Divi Commerce: por Divi Stride – 2.0.6 LiteSpeed Cache: por LiteSpeed Technologies – 4.4.3 PickPlugins Product Slider for WooCommerce: por PickPlugins – 1.13.25 Themify - WooCommerce Product Filter: por Themify – 1.3.5 WooCommerce Blocks: por Automattic – 6.1.0 WooCommerce Shipping & Tax: por WooCommerce – 1.25.19 (la actualización a la versión 1.25.20 está disponible) WOOF - WooCommerce Products Filter: por realmag777 – 2.2.0 WooODT Lite: por ByConsole – 2.2.2 Woo Store Vacation: por MyPreview – 1.4.3 WP Offload Media Lite: por Delicious Brains – 2.5.5 XT WooCommerce Quick View: por XplodedThemes – 1.9.0 YITH Infinite Scrolling: por YITH – 1.5.3 ### Dropin Plugins (1) ### advanced-cache.php: advanced-cache.php ### Must Use Plugins (1) ### ET Support Center :: Must-Use Plugins Autoloader: por Elegant Themes – ### Settings ### API Enabled: ? Force SSL: – Currency: UYU ($) Currency Position: left Thousand Separator: , Decimal Separator: . Number of Decimals: 2 Taxonomies: Product Types: external (external) grouped (grouped) simple (simple) variable (variable) Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog) exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-3) rated-4 (rated-4) rated-5 (rated-5) Connected to WooCommerce.com: ? ### WC Pages ### Base de la tienda: #4 - /tienda/ Carrito: #1801 - /cart/ Finalizar compra: #6 - /finalizar-compra/ Mi cuenta: #1803 - /my-account/ Términos y condiciones: ? Página sin definir ### Theme ### Name: Divi Ecommerce Version: 1.2.3 Author URL: https://divi.space Child Theme: ? Parent Theme Name: Divi Parent Theme Version: 4.6.6 Parent Theme Author URL: https://www.elegantthemes.com WooCommerce Support: ? ### Templates ### Overrides: – ### Action Scheduler ### Cancelada: 10 Oldest: 2021-11-06 12:38:11 -0300 Newest: 2021-11-29 21:50:44 -0300 Completo: 13.188 Oldest: 2021-11-07 20:29:43 -0300 Newest: 2021-12-06 11:36:54 -0300 Pendiente: 7 Oldest: 2021-12-06 11:38:40 -0300 Newest: 2021-12-09 10:43:30 -0300 ### Status report information ### Generated at: 2021-12-06 11:38:49 -03:00
Here it is. I want to clarify that this is from the page currently in production. I’ve been working on a development version running with docker.
Hey @facumidvetkin,
Thanks for sending that over. This is definitely going to require some coding to make it work. The best places to get help with coding questions are on Slack or Facebook. Since those have become more popular, there aren’t as many developers participating in the forums. I think you’d have better chances of getting help in one of these spots:
- WooCommerce Slack Community: https://woocommerce.com/community-slack/
- WooCommerce Community group on Facebook: https://www.facebook.com/groups/advanced.woocommerce/
Take care
This thread has been inactive for a bit, so I’m going to mark it as resolved now.
Please feel free to open a new thread if you have any further questions.
- The topic ‘Show shipping methods by map location’ is closed to new replies.