summaryrefslogtreecommitdiffstats
path: root/system/libraries
diff options
context:
space:
mode:
Diffstat (limited to 'system/libraries')
-rw-r--r--system/libraries/Cache/drivers/Cache_file.php2
-rw-r--r--system/libraries/Cache/drivers/Cache_wincache.php8
-rw-r--r--system/libraries/Calendar.php10
-rw-r--r--system/libraries/Form_validation.php2
-rw-r--r--system/libraries/Ftp.php3
-rw-r--r--system/libraries/Image_lib.php1
-rw-r--r--system/libraries/Javascript.php1
-rw-r--r--system/libraries/Migration.php4
-rw-r--r--system/libraries/Table.php2
-rw-r--r--system/libraries/Upload.php1
10 files changed, 15 insertions, 19 deletions
diff --git a/system/libraries/Cache/drivers/Cache_file.php b/system/libraries/Cache/drivers/Cache_file.php
index 5d370380e..9fd053362 100644
--- a/system/libraries/Cache/drivers/Cache_file.php
+++ b/system/libraries/Cache/drivers/Cache_file.php
@@ -74,7 +74,7 @@ class CI_Cache_file extends CI_Driver {
$data = unserialize(file_get_contents($this->_cache_path.$id));
- if ($data['ttl'] > 0 && time() > $data['time'] + $data['ttl'])
+ if ($data['ttl'] > 0 && time() > $data['time'] + $data['ttl'])
{
unlink($this->_cache_path.$id);
return FALSE;
diff --git a/system/libraries/Cache/drivers/Cache_wincache.php b/system/libraries/Cache/drivers/Cache_wincache.php
index 383b3afdd..9154f3fce 100644
--- a/system/libraries/Cache/drivers/Cache_wincache.php
+++ b/system/libraries/Cache/drivers/Cache_wincache.php
@@ -127,10 +127,10 @@ class CI_Cache_wincache extends CI_Driver {
$hitcount = $stored['ucache_entries'][1]['hitcount'];
return array(
- 'expire' => $ttl - $age,
- 'hitcount' => $hitcount,
- 'age' => $age,
- 'ttl' => $ttl
+ 'expire' => $ttl - $age,
+ 'hitcount' => $hitcount,
+ 'age' => $age,
+ 'ttl' => $ttl
);
}
diff --git a/system/libraries/Calendar.php b/system/libraries/Calendar.php
index caa496a5e..ec2b7bcc1 100644
--- a/system/libraries/Calendar.php
+++ b/system/libraries/Calendar.php
@@ -160,7 +160,7 @@ class CI_Calendar {
// Set and validate the supplied month/year
if (empty($year))
{
- $year = date('Y', $this->local_time);
+ $year = date('Y', $this->local_time);
}
elseif (strlen($year) === 1)
{
@@ -219,8 +219,8 @@ class CI_Calendar {
// "previous" month link
if ($this->show_next_prev === TRUE)
{
- // Add a trailing slash to the URL if needed
- $this->next_prev_url = preg_replace('/(.+?)\/*$/', '\\1/', $this->next_prev_url);
+ // Add a trailing slash to the URL if needed
+ $this->next_prev_url = preg_replace('/(.+?)\/*$/', '\\1/', $this->next_prev_url);
$adjusted_date = $this->adjust_date($month - 1, $year);
$out .= str_replace('{previous_url}', $this->next_prev_url.$adjusted_date['year'].'/'.$adjusted_date['month'], $this->temp['heading_previous_cell'])."\n";
@@ -444,7 +444,7 @@ class CI_Calendar {
*/
public function default_template()
{
- return array(
+ return array(
'table_open' => '<table border="0" cellpadding="4" cellspacing="0">',
'heading_row_start' => '<tr>',
'heading_previous_cell' => '<th><a href="{previous_url}">&lt;&lt;</a></th>',
@@ -490,7 +490,7 @@ class CI_Calendar {
$today = array('cal_cell_start_today', 'cal_cell_content_today', 'cal_cell_no_content_today', 'cal_cell_end_today');
- foreach (array('table_open', 'table_close', 'heading_row_start', 'heading_previous_cell', 'heading_title_cell', 'heading_next_cell', 'heading_row_end', 'week_row_start', 'week_day_cell', 'week_row_end', 'cal_row_start', 'cal_cell_start', 'cal_cell_content', 'cal_cell_no_content', 'cal_cell_blank', 'cal_cell_end', 'cal_row_end', 'cal_cell_start_today', 'cal_cell_content_today', 'cal_cell_no_content_today', 'cal_cell_end_today') as $val)
+ foreach (array('table_open', 'table_close', 'heading_row_start', 'heading_previous_cell', 'heading_title_cell', 'heading_next_cell', 'heading_row_end', 'week_row_start', 'week_day_cell', 'week_row_end', 'cal_row_start', 'cal_cell_start', 'cal_cell_content', 'cal_cell_no_content', 'cal_cell_blank', 'cal_cell_end', 'cal_row_end', 'cal_cell_start_today', 'cal_cell_content_today', 'cal_cell_no_content_today', 'cal_cell_end_today') as $val)
{
if (preg_match('/\{'.$val.'\}(.*?)\{\/'.$val.'\}/si', $this->template, $match))
{
diff --git a/system/libraries/Form_validation.php b/system/libraries/Form_validation.php
index b7bd280ee..e4eac04ba 100644
--- a/system/libraries/Form_validation.php
+++ b/system/libraries/Form_validation.php
@@ -1443,7 +1443,7 @@ class CI_Form_validation {
*/
public function encode_php_tags($str)
{
- return str_replace(array('<?', '?>'), array('&lt;?', '?&gt;'), $str);
+ return str_replace(array('<?', '?>'), array('&lt;?', '?&gt;'), $str);
}
// --------------------------------------------------------------------
diff --git a/system/libraries/Ftp.php b/system/libraries/Ftp.php
index 60c03b5ad..7f58fee7b 100644
--- a/system/libraries/Ftp.php
+++ b/system/libraries/Ftp.php
@@ -460,7 +460,7 @@ class CI_FTP {
}
// Add a trailing slash to the file path if needed
- $filepath = preg_replace('/(.+?)\/*$/', '\\1/', $filepath);
+ $filepath = preg_replace('/(.+?)\/*$/', '\\1/', $filepath);
$list = $this->list_files($filepath);
@@ -636,7 +636,6 @@ class CI_FTP {
'xml'
);
-
return in_array($ext, $text_types) ? 'ascii' : 'binary';
}
diff --git a/system/libraries/Image_lib.php b/system/libraries/Image_lib.php
index 7f937f99b..46a9c120f 100644
--- a/system/libraries/Image_lib.php
+++ b/system/libraries/Image_lib.php
@@ -1373,7 +1373,6 @@ class CI_Image_lib {
if ($image_type === '')
$image_type = $this->image_type;
-
switch ($image_type)
{
case 1 :
diff --git a/system/libraries/Javascript.php b/system/libraries/Javascript.php
index 9a15cddaa..420b623ee 100644
--- a/system/libraries/Javascript.php
+++ b/system/libraries/Javascript.php
@@ -586,7 +586,6 @@ class CI_Javascript {
return $this->js->_show($element, $speed, $callback);
}
-
// --------------------------------------------------------------------
/**
diff --git a/system/libraries/Migration.php b/system/libraries/Migration.php
index bf2d18e07..e591ab64a 100644
--- a/system/libraries/Migration.php
+++ b/system/libraries/Migration.php
@@ -143,8 +143,8 @@ class CI_Migration {
// Migration basename regex
$this->_migration_regex = ($this->_migration_type === 'timestamp')
- ? '/^\d{14}_(\w+)$/'
- : '/^\d{3}_(\w+)$/';
+ ? '/^\d{14}_(\w+)$/'
+ : '/^\d{3}_(\w+)$/';
// Make sure a valid migration numbering type was set.
if ( ! in_array($this->_migration_type, array('sequential', 'timestamp')))
diff --git a/system/libraries/Table.php b/system/libraries/Table.php
index 886fb6581..3d53b1c00 100644
--- a/system/libraries/Table.php
+++ b/system/libraries/Table.php
@@ -527,7 +527,7 @@ class CI_Table {
*/
protected function _default_template()
{
- return array(
+ return array(
'table_open' => '<table border="0" cellpadding="4" cellspacing="0">',
'thead_open' => '<thead>',
diff --git a/system/libraries/Upload.php b/system/libraries/Upload.php
index b3e9f7515..5d163fb77 100644
--- a/system/libraries/Upload.php
+++ b/system/libraries/Upload.php
@@ -294,7 +294,6 @@ class CI_Upload {
'client_name' => ''
);
-
foreach ($defaults as $key => $val)
{
if (isset($config[$key]))