标签: shipping

在Paypal网站付款标准结账时发送POST变量

Paypal网站付款标准结账的正确发货POST变量是什么?

我花了很多时间来运送Paypal网站付款标准结账.实际上我也在使用IPN,但这与此无关,这是关于从我的购物车中获取运费和手续费以显示在paypal结账并更换paypal运费计算器.

我发现的事情:

  • 要让它识别您的购物车的运输/处理应覆盖其计算器,请转到商家帐户资料,设置至少一种运输方式(资料>销售偏好>运费计算)并勾选"使用运费"中的框事务而不是......"[顺便说一下如何找到已经改变并且不再有详细记录].
  • 您在POST中应该具有的变量(来自您网站上的paypal按钮)在此处记录但是文档错误地称为"处理",应该称为"handling_cart".
  • 关于"运输"的文档也是错误的,我找不到正确的名称.我有一个解决方法:虽然文档说你在整个购物车上传[cmd ="_cart"]时无法上传每件商品,但实际上你可以.所以我的工作是为除第一项以外的所有项目设置shipping_x等于零,并将整个运费计入第一项,即:shipping_1 = <运费>

所以我希望能帮助后来的人.而且我希望Paypal能够在文档中共同行动,这对我来说完全是浪费时间.

但除此之外 - 是否有更好的方式来进行运输?如果不是"运输"而不是"shipping_cart",该变量应该被称为什么?在任何地方都有最新的文档吗?

api post paypal shipping

5
推荐指数
1
解决办法
1804
查看次数

Magento:如何在结帐页面更改送货方式标题?

基本上我想要做的是在结帐页面上,我试图将 USPS 的“First-Class Mail Parcel”更改为“First-Class Mail Parcel(3-5 个工作日)”,“Priority Mail”更改为“优先邮件(2-3 个工作日)”和“特快专递”到“特快专递(下一工作日)”。

已经尝试使用以下链接中建议的 translate.csv 解决方案。出于某种原因,它只更改了 UPS 文本,而使 USPS 保持不变。

如何在注册和结帐过程中更改 magento 中的“运输信息”标签

还尝试通过管理面板使用内联翻译,但无法使其正常工作。反正讨厌那个功能。每当您移动鼠标时,这本书都会不断移动,这使得点击框变得非常困难。

必须有一种方法来改变这一点......任何帮助将不胜感激。现在已经在谷歌和论坛上搜索了几个小时,以获得这样一个看似简单的解决方案。

checkout shipping magento

5
推荐指数
1
解决办法
1万
查看次数

Aramex Rate计算器APT返回错误代码"ISE01"

Aramex Rate计算器API返回错误代码ISE01和以下错误消息:

在请求时获取计算率时发生内部服务器错误

这个错误的原因是什么?

以下是Aramex费率计算器API的示例代码:

<?php
$params = array(
    'ClientInfo'            => array(
                                'AccountCountryCode'    => 'JO',
                                'AccountEntity'         => 'AMM',
                                'AccountNumber'         => '00000',
                                'AccountPin'            => '000000',
                                'UserName'              => 'user@company.com',
                                'Password'              => '000000000',
                                'Version'               => 'v1.0'
                            ),

    'Transaction'           => array(
                                'Reference1'            => '001' 
                            ),

    'OriginAddress'         => array(
                                'City'                  => 'Amman',
                                'CountryCode'               => 'JO'
                            ),

    'DestinationAddress'    => array(
                                'City'                  => 'Dubai',
                                'CountryCode'           => 'AE'
                            ),
    'ShipmentDetails'       => array(
                                'PaymentType'            => 'P',
                                'ProductGroup'           => 'EXP',
                                'ProductType'            => 'PPX',
                                'ActualWeight'           => array('Value' => 5, …
Run Code Online (Sandbox Code Playgroud)

php shipping aramex

5
推荐指数
1
解决办法
1297
查看次数

woocommerce_shipping_free_shipping_is_available 不起作用

我在 WordPress 安装中对 WooCommerce 进行了自定义。

我有类似的东西:

/**
 * Disable free shipping for select products
 *
 * @param bool $is_available
 */
function my_free_shipping( $is_available ) {
    global $woocommerce;

    // set the product ids that are ineligible
    $ineligible = array( '14009', '14031' );

    // get cart contents
    $cart_items = $woocommerce->cart->get_cart();

    // loop through the items looking for one in the ineligible array
    foreach ( $cart_items as $key => $item ) {
        if( in_array( $item['product_id'], $ineligible ) ) {
            return false;
        }
    } …
Run Code Online (Sandbox Code Playgroud)

php wordpress shipping woocommerce hook-woocommerce

5
推荐指数
0
解决办法
2013
查看次数

在WooCommerce电子邮件通知中隐藏本地取件的送货地址

如果选择了“本地取件”,如何隐藏客户处理电子邮件中的“收货地址”信息部分?

我不知道如何为此提供代码。

在此处输入图片说明

php wordpress shipping email-notifications woocommerce

5
推荐指数
1
解决办法
1773
查看次数

Woocommerce定制运输价格含税

我有添加的自定义运输方法来计算运输,并使用以下代码

public function calculate_shipping( $package ) {
                $postcode_data = $package['destination']['postcode'];
                if(!empty($postcode_data)){
                $weight = 0;    
                $zone_data = checkzone($postcode_data);
                if(isset($package['destination']['postcode'])){
                if(!empty($zone_data)){     
                $weight = WC()->cart->cart_contents_weight;  // get cart total weight   
                if($weight <= 100){
                    $weight_range = ceil($weight / 10 );
                }
                elseif(($weight > 100 ) && ($weight < 150) ){
                    $weight_range = 11 ; 
                }
                if($weight >= 150) 
                {
                    $weight_range = 12 ; 
                }

                $pricing = getpricing($zone_data , $weight_range); 


                if($pricing > 0){                   
                $rate = array(
                    'id' => $this->id,
                    'label' => 'Delivery',
                    'cost' => $pricing, …
Run Code Online (Sandbox Code Playgroud)

php wordpress shipping woocommerce

5
推荐指数
0
解决办法
363
查看次数

在产品页面上显示运费 - WooCommerce

我正在尝试在 Wordpress 上制作一个自定义页面,该页面以一种形式显示 2 种订阅类型,每种类型有 3 种变体(每月、6 个月、12 个月)。每个变体都有一个单选按钮,当用户单击单选按钮时,我有一个实时更新的总价格。这部分正在工作。

但是现在,我想添加 3 个其他单选按钮来选择发货方式。(当用户选择一个时,它也会实时更新总价)。

我一直在寻找如何获得产品的运费很长时间,但没有任何效果。

有谁知道 :) ?

php wordpress shipping woocommerce woocommerce-subscriptions

5
推荐指数
1
解决办法
1万
查看次数

隐藏woocommerce中特定送货类的送货方式

基本上我正在尝试使用具有运输类别"Roller"(ID )的购物车物品时flat_rate:7 禁用统一费率方法ID 92.

这是我试过的代码:

add_filter('woocommerce_package_rates', 'wf_hide_shipping_method_based_on_shipping_class', 10, 2);

function wf_hide_shipping_method_based_on_shipping_class($available_shipping_methods, $package)
{
    $hide_when_shipping_class_exist = array(
        92 => array(
            'flat_rate:7'
        )
    );

    $shipping_class_in_cart = array();
    foreach(WC()->cart->cart_contents as $key => $values) {
       $shipping_class_in_cart[] = $values['data']->get_shipping_class_id();
    }

    foreach($hide_when_shipping_class_exist as $class_id => $methods) {
        if(in_array($class_id, $shipping_class_in_cart)){
            foreach($methods as & $current_method) {
                unset($available_shipping_methods[$current_method]);
            }
        }
    }

    return $available_shipping_methods;
}
Run Code Online (Sandbox Code Playgroud)

发货类ID 92是发货类,我想隐藏flat_rate:7它.

我的网站是这样的:http://www.minimoto.me/ WordPress:4.8.4 WooCommerce:3.1.1

任何帮助将不胜感激.

php wordpress shipping cart woocommerce

5
推荐指数
1
解决办法
3932
查看次数

Get All Shipping Classes in Woocommerce 3

I've been unable to crack this nut, but can't help feel that I'm missing something simple.

I'm developing a WooCommerce plugin that should provide a list of shipping classes on its admin settings page. The following code as suggested in another question's answer indicated that the following should work:

$shipping           = new \WC_Shipping();
$shipping_classes   = $shipping->get_shipping_classes();
var_dump($shipping_classes);
die();
Run Code Online (Sandbox Code Playgroud)

Unfortunately the output is an empty array.

I am using Wordpress 4.9.5 and WooCommerce 3.3.5. Thanks for any help!

UPDATE I have …

php wordpress shipping custom-taxonomy woocommerce

5
推荐指数
1
解决办法
2538
查看次数

在 Woocommerce 中设置本地取货运输方式的百分比折扣

我有一个使用 WooCommerce 插件的 WordPress 网站。如果买家选择本地取货作为运输方式,我想为他们提供购物车总额 5% 的折扣。

我已经尝试过- 5 * [qty]但它似乎不起作用。

我也试过 -0.95 * [cost] 没有运气

在此处输入图片说明 在此处输入图片说明

php wordpress shipping discount woocommerce

5
推荐指数
1
解决办法
2901
查看次数