wpdesk / wp-ups-shipping-method
UPS Shipping Method
This package's canonical repository appears to be gone and the package has been frozen as a result. Email us for help if needed.
Package info
gitlab.wpdesk.dev/wpdesk/wp-ups-shipping-method
pkg:composer/wpdesk/wp-ups-shipping-method
3.5.0
2024-08-13 11:54 UTC
Requires
- php: >=7.4
- octolize/wp-ups-oauth: ^1.0
- psr/log: ^1.1
- wpdesk/abstract-shipping: ^2.11
- wpdesk/ups-shipping-service: ^3.1
- wpdesk/wp-woocommerce-shipping: ^3.7.9
Requires (Dev)
- 10up/wp_mock: *
- mockery/mockery: *
- phpcompatibility/php-compatibility: ^9.1
- phpunit/phpunit: <7
- squizlabs/php_codesniffer: ^3.0.2
- wp-coding-standards/wpcs: ^0.14.1
This package is auto-updated.
Last update: 2024-09-13 12:09:44 UTC
README
UPS Shipping Method
Allows to integrate WooCommerce shipping methods interface with UPS rates calculation mechanism and services.
This library uses the following:
- https://gitlab.com/wpdesk/predators/library/abstract-shipping
- https://gitlab.com/wpdesk/wp-woocommerce-shipping
- https://gitlab.com/wpdesk/wp-ups-shipping-method
- https://gitlab.com/wpdesk/predators/library/ups-shipping-service
Requirements
PHP 7.0 or later.
Installation via Composer
In order to install the bindings via Composer run the following command:
composer require wpdesk/wp-ups-shipping-method
Example usage
<?php
...
public function hooks() {
add_filter( 'woocommerce_shipping_methods', array( $this, 'add_ups_shipping_method' ) );
}
/**
* Adds shipping method to Woocommerce.
*
* @param array $methods Methods.
*
* @return array
*/
public function add_ups_shipping_method( $methods ) {
$methods['flexible_shipping_ups'] = \WPDesk\WooCommerceShipping\Ups\UpsShippingMethod::class;
return $methods;
}
...