我在模态窗口中有一个表单在Chrome中工作得很好但是当我在Firefox中提取表单时,表单控件选择组件在从选项中选择一个时实际上没有选择该值。它在实现方面是一个非常标准的形式,它只是不想在Firefox中工作。表格的一部分如下:
<?php
class Products extends CI_Controller{
public function __construct(){
parent::__construct();
}
public function index(){
//get all products
$data['products'] = $this->Product_model->get_products();
//load view
$data['main_content'] = 'products';
$this->load->view('layouts/main', $data);
}
public function details($id){
//get product details from the model
$data['product'] = $this->Product_model->get_product_details($id);
//load view
$data['main_content'] = 'details';
$this->load->view('layouts/main', $data);
}
public function addtocart(){
// here you can collect submitted product values such as item_number, price, name
echo '<pre>';
print_r($_POST);
}
}
}