Pagination please |
[eluser]RaiNnTeaRs[/eluser]
Hi..can someone help me ( again ) with paging ? i dont get how it works... I understand that we need controllers and view models to create something with Ci my controller name is : dojang.php and my view file is : news_view.php index.php is located in www.localhost.com/ci2/index.php in this news_view i Have 20 lines of rows and i would like to separate them into pages 1st page : 1..10 2nd page : 11..20 I've wrote this code on my controller file (dojang.php) and it didnt work, can someone help me solve this problem ? thanks a million lol. $this->db->from('tabel_news'); $this->db->orderby("tanggal","asc"); $query = $this->db->get(); $data['query']=$query; $config['base_url']='http://192.168.1.188/ci2/index.php/dojang/news_view'; $config['total_rows']='200'; $config['per_page']='10'; $config['uri_segment']='4'; $this->pagination->initialize($config); echo $this->pagination->create_links(); //LOAD VIEW $this->load->view('news_view',$data); |
Messages In This Thread |
Pagination please - by El Forum - 04-13-2008, 11:05 PM
Pagination please - by El Forum - 04-13-2008, 11:34 PM
Pagination please - by El Forum - 04-13-2008, 11:48 PM
Pagination please - by El Forum - 04-13-2008, 11:53 PM
Pagination please - by El Forum - 04-14-2008, 12:18 AM
Pagination please - by El Forum - 04-15-2008, 12:37 AM
Pagination please - by El Forum - 04-15-2008, 12:48 AM
Pagination please - by El Forum - 04-15-2008, 01:31 PM
Pagination please - by El Forum - 04-28-2008, 04:31 AM
Pagination please - by El Forum - 04-28-2008, 04:42 AM
Pagination please - by El Forum - 05-03-2008, 08:08 AM
|