0
아무도 도와 줄 수 있습니까? 내 테이블을 매김하려고합니다. 모든 링크가 작동하지만 항목이 다른 페이지에서 반복됩니다. 나는 여기에 비슷한 질문을했지만 아무것도 작동하지 않습니다.codeigniter 페이지 매김 : 링크는 작동하지만 레코드는 다른 페이지에서 반복됩니다.
function index($type="deposit", $limit_from=0)
{
$limit_from = ($this->uri->segment(4)) ? $this->uri->segment(4) : 0;
$total_records = $this->Expense->get_total_rows($type);
$data['controller_name'] = $this->get_controller_name();
$lines_per_page = 3;
$data[$type.'s'] = $this->Expense->get_records($lines_per_page, $limit_from, $type);
$config['base_url'] = base_url('index.php/expenses/index/'.$type);
$config['total_rows'] = $total_records;
$config['per_page'] = 3;
$config["uri_segment"] = 4;
// $choice = $total_records/$config['per_page'];
// $config['num_links'] = round($choice);
$config['use_page_numbers'] = TRUE;
$config['first_url'] = base_url('index.php/expenses/index/'.$type.'/1');
$this->pagination->initialize($config);
$data["links"] = $this->pagination->create_links();
$this->load->view('expenses/'.$type, $data);
$this->_remove_duplicate_cookies();
}
안녕하세요, 것은 어쩌면 당신이 도움을받을 것입니다이 링크를 참조하시기 바랍니다! https://www.formget.com/pagination-in-codeigniter/ – Afzal