From 11c5f1654d2d13113ad06da46f560628d7e31dd3 Mon Sep 17 00:00:00 2001
From: Aaron Kuzemchak
The number of "digit" links you would like before and after the selected page number. For example, the number 2 will place two digits on either side, as in the example links at the very top of this page.
-By default, the URI segment will use the starting index for the items you are paginating. If you prefer to show the the actual page number, set this to TRUE.
+ +By default, the pagination library assume you are using URI Segments, and constructs your links something like
http://example.com/index.php/test/page/20
If you have $config['enable_query_strings'] set to TRUE your links will automatically be re-written using Query Strings. This option can also be explictly set. Using $config['page_query_string'] set to TRUE, the pagination link will become.
-- cgit v1.2.3-24-g4f1b From 61bb5012ba51ebbe5af11ef9d21741474f9f970d Mon Sep 17 00:00:00 2001 From: Bo-Yi WuPermits you to set the mime-type of your page so you can serve JSON data, JPEG's, XML, etc easily.
-$this->output
- ->set_content_type('application/json')
- ->set_output(json_encode(array('foo' => 'bar')));
-
-$this->output
- ->set_content_type('jpeg') // You could also use ".jpeg" which will have the full stop removed before looking in config/mimes.php
+$this->output
+ ->set_content_type('application/json')
+ ->set_output(json_encode(array('foo' => 'bar')));
+
+$this->output
+ ->set_content_type('jpeg') // You could also use ".jpeg" which will have the full stop removed before looking in config/mimes.php
->set_output(file_get_contents('files/something.jpg'));
Important: Make sure any non-mime string you pass to this method exists in config/mimes.php or it will have no effect.
@@ -174,4 +174,4 @@ Next Topic: Pagination Class