diff options
author | Andrey Andreev <narf@devilix.net> | 2014-02-09 16:30:06 +0100 |
---|---|---|
committer | Andrey Andreev <narf@devilix.net> | 2014-02-09 16:30:06 +0100 |
commit | c2804a3f3eb085abcc50e8df51085db7a94c18d2 (patch) | |
tree | b53e8a2798a75fa4f92ee2cc3201635ce7df319a /system/libraries | |
parent | f6600f840125eadf2366c2244f78ad95defb156b (diff) | |
parent | db97fe561f03284a287c9a588ac1ff19a9f5e71d (diff) |
Merge branch 'develop' into 'feature/encryption'
Diffstat (limited to 'system/libraries')
-rw-r--r-- | system/libraries/Calendar.php | 12 | ||||
-rw-r--r-- | system/libraries/Email.php | 2 | ||||
-rw-r--r-- | system/libraries/Form_validation.php | 7 | ||||
-rw-r--r-- | system/libraries/Javascript.php | 1 | ||||
-rw-r--r-- | system/libraries/Pagination.php | 4 | ||||
-rw-r--r-- | system/libraries/Table.php | 72 |
6 files changed, 56 insertions, 42 deletions
diff --git a/system/libraries/Calendar.php b/system/libraries/Calendar.php index 711d23bec..610b427cf 100644 --- a/system/libraries/Calendar.php +++ b/system/libraries/Calendar.php @@ -139,7 +139,7 @@ class CI_Calendar { * Accepts an associative array as input, containing display preferences * * @param array config preferences - * @return void + * @return CI_Calendar */ public function initialize($config = array()) { @@ -156,6 +156,8 @@ class CI_Calendar { { $this->next_prev_url = $this->CI->config->site_url($this->CI->router->class.'/'.$this->CI->router->method); } + + return $this; } // -------------------------------------------------------------------- @@ -362,7 +364,7 @@ class CI_Calendar { * Get Day Names * * Returns an array of day names (Sunday, Monday, etc.) based - * on the type. Options: long, short, abrev + * on the type. Options: long, short, abr * * @param string * @return array @@ -513,7 +515,7 @@ class CI_Calendar { * Harvests the data within the template {pseudo-variables} * used to display the calendar * - * @return void + * @return CI_Calendar */ public function parse_template() { @@ -521,7 +523,7 @@ class CI_Calendar { if ($this->template === '') { - return; + return $this; } $today = array('cal_cell_start_today', 'cal_cell_content_today', 'cal_cell_no_content_today', 'cal_cell_end_today'); @@ -537,6 +539,8 @@ class CI_Calendar { $this->temp[$val] = $this->temp[substr($val, 0, -6)]; } } + + return $this; } } diff --git a/system/libraries/Email.php b/system/libraries/Email.php index f4efff882..88925e03f 100644 --- a/system/libraries/Email.php +++ b/system/libraries/Email.php @@ -822,7 +822,7 @@ class CI_Email { * @param string * @return CI_Email */ - public function set_alt_message($str = '') + public function set_alt_message($str) { $this->alt_message = (string) $str; return $this; diff --git a/system/libraries/Form_validation.php b/system/libraries/Form_validation.php index 58485916c..7c441409f 100644 --- a/system/libraries/Form_validation.php +++ b/system/libraries/Form_validation.php @@ -252,7 +252,7 @@ class CI_Form_validation { * each array due to the limitations of CI's singleton * * @param array $data - * @return void + * @return CI_Form_validation */ public function set_data(array $data) { @@ -260,6 +260,8 @@ class CI_Form_validation { { $this->validation_data = $data; } + + return $this; } // -------------------------------------------------------------------- @@ -1536,7 +1538,7 @@ class CI_Form_validation { * Prevents subsequent validation routines from being affected by the * results of any previous validation routine due to the CI singleton. * - * @return void + * @return CI_Form_validation */ public function reset_validation() { @@ -1545,6 +1547,7 @@ class CI_Form_validation { $this->_error_array = array(); $this->_error_messages = array(); $this->error_string = ''; + return $this; } } diff --git a/system/libraries/Javascript.php b/system/libraries/Javascript.php index 26a16850c..34a216c22 100644 --- a/system/libraries/Javascript.php +++ b/system/libraries/Javascript.php @@ -34,6 +34,7 @@ defined('BASEPATH') OR exit('No direct script access allowed'); * @category Javascript * @author EllisLab Dev Team * @link http://codeigniter.com/user_guide/libraries/javascript.html + * @deprecated 3.0.0 This was never a good idea in the first place. */ class CI_Javascript { diff --git a/system/libraries/Pagination.php b/system/libraries/Pagination.php index c6ffd03d4..f67cb47f8 100644 --- a/system/libraries/Pagination.php +++ b/system/libraries/Pagination.php @@ -314,7 +314,7 @@ class CI_Pagination { * Initialize Preferences * * @param array $params Initialization parameters - * @return void + * @return CI_Pagination */ public function initialize($params = array()) { @@ -342,6 +342,8 @@ class CI_Pagination { } } } + + return $this; } // -------------------------------------------------------------------- diff --git a/system/libraries/Table.php b/system/libraries/Table.php index b77fcf19d..1d4320855 100644 --- a/system/libraries/Table.php +++ b/system/libraries/Table.php @@ -117,7 +117,7 @@ class CI_Table { /** * Set the template * - * @param array + * @param array $template * @return bool */ public function set_template($template) @@ -139,12 +139,13 @@ class CI_Table { * Can be passed as an array or discreet params * * @param mixed - * @return void + * @return CI_Table */ public function set_heading($args = array()) { $args = func_get_args(); $this->heading = $this->_prep_args($args); + return $this; } // -------------------------------------------------------------------- @@ -155,9 +156,9 @@ class CI_Table { * columns. This allows a single array with many elements to be * displayed in a table that has a fixed column count. * - * @param array - * @param int - * @return void + * @param array $array + * @param int $col_limit + * @return array */ public function make_columns($array = array(), $col_limit = 0) { @@ -202,12 +203,13 @@ class CI_Table { * * Can be passed as an array or discreet params * - * @param mixed - * @return void + * @param mixed $value + * @return CI_Table */ public function set_empty($value) { $this->empty_cells = $value; + return $this; } // -------------------------------------------------------------------- @@ -218,12 +220,13 @@ class CI_Table { * Can be passed as an array or discreet params * * @param mixed - * @return void + * @return CI_Table */ public function add_row($args = array()) { $args = func_get_args(); $this->rows[] = $this->_prep_args($args); + return $this; } // -------------------------------------------------------------------- @@ -271,8 +274,8 @@ class CI_Table { /** * Add a table caption * - * @param string - * @return void + * @param string $caption + * @return CI_Table */ public function set_caption($caption) { @@ -284,7 +287,7 @@ class CI_Table { /** * Generate the table * - * @param mixed + * @param mixed $table_data * @return string */ public function generate($table_data = NULL) @@ -417,13 +420,14 @@ class CI_Table { /** * Clears the table arrays. Useful if multiple tables are being generated * - * @return void + * @return CI_Table */ public function clear() { - $this->rows = array(); - $this->heading = array(); - $this->auto_heading = TRUE; + $this->rows = array(); + $this->heading = array(); + $this->auto_heading = TRUE; + return $this; } // -------------------------------------------------------------------- @@ -528,31 +532,31 @@ class CI_Table { protected function _default_template() { return array( - 'table_open' => '<table border="0" cellpadding="4" cellspacing="0">', + 'table_open' => '<table border="0" cellpadding="4" cellspacing="0">', - 'thead_open' => '<thead>', - 'thead_close' => '</thead>', + 'thead_open' => '<thead>', + 'thead_close' => '</thead>', - 'heading_row_start' => '<tr>', - 'heading_row_end' => '</tr>', - 'heading_cell_start' => '<th>', - 'heading_cell_end' => '</th>', + 'heading_row_start' => '<tr>', + 'heading_row_end' => '</tr>', + 'heading_cell_start' => '<th>', + 'heading_cell_end' => '</th>', - 'tbody_open' => '<tbody>', - 'tbody_close' => '</tbody>', + 'tbody_open' => '<tbody>', + 'tbody_close' => '</tbody>', - 'row_start' => '<tr>', - 'row_end' => '</tr>', - 'cell_start' => '<td>', - 'cell_end' => '</td>', + 'row_start' => '<tr>', + 'row_end' => '</tr>', + 'cell_start' => '<td>', + 'cell_end' => '</td>', - 'row_alt_start' => '<tr>', - 'row_alt_end' => '</tr>', - 'cell_alt_start' => '<td>', - 'cell_alt_end' => '</td>', + 'row_alt_start' => '<tr>', + 'row_alt_end' => '</tr>', + 'cell_alt_start' => '<td>', + 'cell_alt_end' => '</td>', - 'table_close' => '</table>' - ); + 'table_close' => '</table>' + ); } } |