Add language translation support to CI_Pagination (#1589)
diff --git a/system/libraries/Pagination.php b/system/libraries/Pagination.php
index da4b892..2f1bcfb 100644
--- a/system/libraries/Pagination.php
+++ b/system/libraries/Pagination.php
@@ -304,6 +304,16 @@
 	 */
 	public function __construct($params = array())
 	{
+		$CI =& get_instance();
+		$CI->load->language('paginaton');
+		foreach (array('first_link', 'next_link', 'prev_link', 'last_link') as $key)
+		{
+			if (($val = $CI->lang->line('pagination_'.$key)) !== FALSE)
+			{
+				$this->$key = $val;
+			}
+		}
+
 		$this->initialize($params);
 		log_message('debug', 'Pagination Class Initialized');
 	}
@@ -316,7 +326,7 @@
 	 * @param	array	$params	Initialization parameters
 	 * @return	CI_Pagination
 	 */
-	public function initialize($params = array())
+	public function initialize(array $params = array())
 	{
 		if (isset($params['attributes']) && is_array($params['attributes']))
 		{
@@ -332,14 +342,11 @@
 			unset($params['anchor_class']);
 		}
 
-		if (count($params) > 0)
+		foreach ($params as $key => $val)
 		{
-			foreach ($params as $key => $val)
+			if (property_exists($this, $this->$key))
 			{
-				if (isset($this->$key))
-				{
-					$this->$key = $val;
-				}
+				$this->$key = $val;
 			}
 		}
 
diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst
index 029bf61..3bb88a7 100644
--- a/user_guide_src/source/changelog.rst
+++ b/user_guide_src/source/changelog.rst
@@ -367,11 +367,12 @@
 
    -  :doc:`Pagination Library <libraries/pagination>` changes include:
 
+      -  Deprecated usage of the "anchor_class" setting (use the new "attributes" setting instead).
       -  Added method chaining support to ``initialize()`` method.
       -  Added support for the anchor "rel" attribute.
       -  Added support for setting custom attributes.
-      -  Deprecated usage of the "anchor_class" setting (use the new "attributes" setting instead).
-      -  Added $config['reuse_query_string'] to allow automatic repopulation of query string arguments, combined with normal URI segments.
+      -  Added support for language translations of the *first_link*, *next_link*, *prev_link* and *last_link* values.
+      -  Added ``$config['reuse_query_string']`` to allow automatic repopulation of query string arguments, combined with normal URI segments.
       -  Removed the default ``&nbsp;`` from a number of the configuration variables.
 
    -  :doc:`Profiler Library <general/profiling>` changes include:
diff --git a/user_guide_src/source/libraries/pagination.rst b/user_guide_src/source/libraries/pagination.rst
index ee12d9e..d8d31f8 100644
--- a/user_guide_src/source/libraries/pagination.rst
+++ b/user_guide_src/source/libraries/pagination.rst
@@ -165,6 +165,8 @@
 The text you would like shown in the "first" link on the left. If you do
 not want this link rendered, you can set its value to FALSE.
 
+.. note:: This value can also be translated via a language file.
+
 $config['first_tag_open'] = '<div>';
 ====================================
 
@@ -185,6 +187,8 @@
 The text you would like shown in the "last" link on the right. If you do
 not want this link rendered, you can set its value to FALSE.
 
+.. note:: This value can also be translated via a language file.
+
 $config['last_tag_open'] = '<div>';
 ===================================
 
@@ -205,6 +209,8 @@
 The text you would like shown in the "next" page link. If you do not
 want this link rendered, you can set its value to FALSE.
 
+.. note:: This value can also be translated via a language file.
+
 $config['next_tag_open'] = '<div>';
 ===================================
 
@@ -225,6 +231,8 @@
 The text you would like shown in the "previous" page link. If you do not
 want this link rendered, you can set its value to FALSE.
 
+.. note:: This value can also be translated via a language file.
+
 $config['prev_tag_open'] = '<div>';
 ===================================