Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/wordpress/11.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 从Woocommerce电子邮件通知中的订单表中删除发货行_Php_Wordpress_Woocommerce_Shipping_Email Notifications - Fatal编程技术网

Php 从Woocommerce电子邮件通知中的订单表中删除发货行

Php 从Woocommerce电子邮件通知中的订单表中删除发货行,php,wordpress,woocommerce,shipping,email-notifications,Php,Wordpress,Woocommerce,Shipping,Email Notifications,在WooCommerce中,我试图从电子邮件通知中的订单表中删除发货行 我找了很多,但没有找到一个方法 任何帮助都是值得的。要删除电子邮件通知中的发货行,只需在电子邮件/email order details.php模板中添加少量代码即可 这里是从第51行开始的摘录。因此,您将用以下代码替换html开头标记和结尾标记的所有代码: <tfoot> <?php if ( $totals = $order-&g

在WooCommerce中,我试图从电子邮件通知中的订单表中删除发货行

我找了很多,但没有找到一个方法

任何帮助都是值得的。

要删除电子邮件通知中的发货行,只需在
电子邮件/email order details.php
模板中添加少量代码即可

这里是从第51行开始的摘录。因此,您将用以下代码替换html开头
标记和结尾
标记的所有代码:

        <tfoot>
            <?php
                if ( $totals = $order->get_order_item_totals() ) {
                    $i = 0;
                    foreach ( $totals as $key_total => $total ) {
                        $i++;
                        if( $key_total != 'shipping' ):
                        ?><tr>
                            <th class="td" scope="row" colspan="2" style="text-align:<?php echo $text_align; ?>; <?php echo ( 1 === $i ) ? 'border-top-width: 4px;' : ''; ?>"><?php echo $total['label']; ?></th>
                            <td class="td" style="text-align:<?php echo $text_align; ?>; <?php echo ( 1 === $i ) ? 'border-top-width: 4px;' : ''; ?>"><?php echo $total['value']; ?></td>
                        </tr><?php
                        endif;
                    }
                }
                if ( $order->get_customer_note() ) {
                    ?><tr>
                        <th class="td" scope="row" colspan="2" style="text-align:<?php echo $text_align; ?>;"><?php _e( 'Note:', 'woocommerce' ); ?></th>
                        <td class="td" style="text-align:<?php echo $text_align; ?>;"><?php echo wptexturize( $order->get_customer_note() ); ?></td>
                    </tr><?php
                }
            ?>
        </tfoot>


你看过模板文件了吗?常识告诉你,我已经查过模板文件@proeviz了。事实上,我使用模板做了很多更改,但没有找到在表中隐藏装运标签的解决方案。