我想在foreach循环中包含文件,但是为什么只包含一次。.
我的数据库中有3个订单存储,我想包含info_customer.php
3次,但只包含一次。
以下是我的代码。
<?php
$ordersinfo = $ordercon->get_orders_by_ids($p_order_id);
foreach ($ordersinfo as $key => $customerInfo) {
$customerDeliveryMethod = $customerInfo['delivery_method'];
if($shipping_method == 5 && $customerDeliveryMethod == 'startrack'){
$_POST['delivery_type'] =$customerDeliveryMethod;
}elseif ($shipping_method==5 && $customerDeliveryMethod == 'austpost') {
$_POST['delivery_type'] =$customerDeliveryMethod;
}
include("info_customer.php");
}
?>
为什么文件只包含一次,我想包含