Linux 软件免费装
Banner图

Gellum Delivery Calculator for WooCommerce

开发者 gellum
venywest
更新时间 2025年6月1日 15:34
捐献地址: 去捐款
PHP版本: 7.4 及以上
WordPress版本: 6.8
版权: GPL v2 or later
版权网址: 版权信息

标签

woocommerce google maps delivery gps shipping calculator

下载

1.0.6 1.0.7

详情介绍:

https://www.youtube.com/watch?v=RXEAB7D3Z5I Calculate Shipping Costs by GPS Distance in WooCommerce with Interactive Map Gellum Delivery Calculator transform your WooCommerce store's local delivery experience. This plugin offers a robust and user-friendly way to calculate shipping costs based on the precise GPS distance from your store to the customer's location. It goes beyond simple calculations by integrating an interactive Google Map directly into your cart or checkout process. Customers can easily pinpoint their exact delivery location on the map, or allow their browser to attempt automatic GPS detection for an even quicker start. You define your operational reach by drawing or uploading a GeoJSON boundary, ensuring that rates are only offered within your designated service area. The plugin visually displays this area on the map, providing clear feedback to the customer. The standout feature is the integration of Google Maps Reverse Geocoding. When a customer selects or moves their pin on the map:
  1. The plugin instantly fetches detailed address information via the Google Geocoding API.
  2. It identifies the Google Plus Code, City, State/Province, Postal Code, and Country. This streamlines the checkout process, reduces typing errors, and enhances the overall user experience by leveraging WooCommerce's native checkout update mechanisms. It's particularly useful for areas where traditional street addresses might be less precise or for customers who prefer the simplicity of dropping a pin.
Key Features:

安装:

  1. Download: Download the plugin .zip file.
  2. Upload: Go to your WordPress Dashboard > Plugins > Add New > Upload Plugin. Select the downloaded .zip file and click 'Install Now'.
  3. Activate: Once installed, click 'Activate Plugin'.
  4. Configure Shipping Zone:
  5. Go to WooCommerce > Settings > Shipping.
  6. Click 'Add shipping zone'. Give it a name (e.g., "Local Delivery Zone"). Assign regions if necessary (though Gellum uses its own GeoJSON).
  7. Click 'Add shipping method'. Select 'Gellum Delivery' from the dropdown and click 'Add shipping method'.
  8. Configure Gellum Delivery:
  9. Hover over 'Gellum Delivery' in your shipping zone and click 'Edit'.
  10. Crucially, enter your Google Maps API Key. Ensure you have enabled both the Maps JavaScript API and the Geocoding API in your Google Cloud Console for this key.
  11. Enter your Store Latitude and Store Longitude. You can find these using Google Maps.
  12. Set up your Base Shipping Rate, Max Distance for Base Rate, and Additional Rate per km.
  13. Define your Delivery Area GeoJSON. You can create this using a tool like geojson.io and paste the code here.
  14. Set a Minimum Order for Free Shipping if desired (set to 0 to disable).
  15. Click 'Save changes'.
  16. Add the Map:
  17. Edit your WooCommerce Cart or Checkout page (or any other page where you want the map).
  18. Add the [gellumdcw_map] shortcode where you want the interactive map to appear.
  19. Test: Place a test order, select a location on the map, and verify that the shipping costs and address fields update correctly.

升级注意事项:

  • 1.0.6 Shortcode Change: If you are a plugin user, you must update the shortcode from [gdc_map] to [gellumdcw_map].
  • 1.0.1 First release: Plugin that automatically calculates the cost of home delivery between the business and the customer.

常见问题:

How do I get a Google Maps API Key?

You need to create a project in the Google Cloud Console, generate an API key, and enable the "Maps JavaScript API" and "Geocoding API" for that key. Remember to restrict your key for security (e.g., by HTTP referrers).

How do I create the GeoJSON for my delivery area?

Use a free online tool like geojson.io. Use the drawing tools (Polygon) to outline your delivery area on the map. Copy the generated GeoJSON code from the right-hand panel and paste it into the plugin settings. Ensure it's a valid GeoJSON FeatureCollection or Polygon/MultiPolygon.

Will it work with my theme's checkout page?

The plugin uses standard WooCommerce hooks and AJAX calls. It's designed to be compatible with most themes. The [gellumdcw_map] shortcode allows you to place the map flexibly. Some highly customized checkouts might require minor CSS adjustments.

Does it update both billing and shipping addresses?

Currently, the JavaScript focuses on updating the billing address fields. If your checkout uses separate shipping fields, you might need to adjust the gellumdcw-frontend.js or implement a filter if you need both updated automatically.

Can I customize the map's appearance?

Yes, there are a couple of ways to customize the map's appearance:

  1. CSS Styling: The included gellumdcw-frontend.css provides basic styling for the map container and related elements. You can override these CSS styles in your theme's style.css file or via the WordPress Customizer's "Additional CSS" section for a more integrated look with your site. This primarily affects the elements around the map (like the info text, error messages).
  2. Google Cloud Map Styling (via Map ID): For advanced customization of the map itself (colors of roads, water, points of interest, density of features, etc.), the plugin now supports Google Maps Cloud-based map styling.
  3. You need to create a Map Style in the Google Cloud Console under "Maps Platform" > "Map Styles".
  4. Then, create a Map ID under "Maps Platform" > "Map IDs", ensuring it's configured for "JavaScript" and "Vector" maps.
  5. Associate your custom Map Style with this Map ID within the Map ID's settings in the Google Cloud Console.
  6. Finally, enter this Map ID into the "Google Maps Map ID" field in the Gellum Delivery Calculator settings in WooCommerce (WooCommerce > Settings > Shipping > [Your Zone] > Gellum Delivery).
  7. When a valid Map ID is provided, the plugin will instruct Google Maps to use the associated cloud-based style, giving you rich visual control over the map's look and feel directly from the Google Cloud Console.
  8. GeoJSON Delivery Area Styling: The appearance of the delivery area (the polygon drawn on the map) can also be customized.
  9. Currently, the plugin styles it as an outline (no fill).
  10. If you need to change the color, stroke weight, or opacity of this delivery area outline, you would need to modify the self.map.data.setStyle({…}) section within the drawDeliveryArea function in the assets/js/gellumdcw-frontend.js file.

Multisite Compatibility

Gellum Delivery Calculator is designed to be fully compatible with WordPress Multisite installations. To configure: Simply activate the plugin on each subsite where you intend to offer Gellum Delivery, and then set up its specific settings within the WooCommerce Shipping Zone configuration for that particular subsite.

更新日志:

1.0.7 (2025-05-30) 1.0.6 (2025-05-30) 1.0.5 (2025-05-26) 1.0.4 (2025-05-26) 1.0.3 (2025-05-26) 1.0.2 (2025-05-24) 1.0.1 (2025-05-23) 1.0.0 (2025-05-20)