0
的出現導致啓動文件的循環:只卸載特定類型的數據庫
<?php
$result_for_base_a = $this->db->query("SELECT * FROM oc_order_option WHERE order_id = '$id'");
for($j = 0; $j<count($result_for_base_a->rows); $j++) {
$product_option_value_id = $result_for_base_a->rows[$j]['product_option_value_id'];
$product_option_id = $result_for_base_a->rows[$j]['product_option_id'];
$result_for_base_c = $this->db->query("SELECT * FROM oc_product_option WHERE product_option_id = '$product_option_id'");
$product_id = $result_for_base_c->row['product_id'];
$result_for_base_b = $this->db->query("SELECT * FROM oc_product_option_value WHERE product_option_value_id = '$product_option_value_id' AND product_id='$product_id'");
$points = $result_for_base_b->row['points'];
$price = $result_for_base_b->row['price'];
$counts = $result_for_base_a->rows[$j]['quantity'];
}
我需要補充,會爲只有那些選擇選項,創建可啓動數據的規則。
表有「型」,還有一個選擇,多選,電臺,圖像等,但我需要循環忽略所有類型,除了選擇。