summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-06-07 12:00:14 +0200
committerAndrey Andreev <narf@bofh.bg>2012-06-07 12:00:14 +0200
commit2ba089ef2e8b0a569b80c822337a6f6f3e928df0 (patch)
treeea4ecd5c6c61cd156bb72c6cf86c6bd04708e9e4
parent62875bc789b60d95aa73fddda87d69fc88c66558 (diff)
parenta6f3423388c2c51119e71d7aac2917b34911bf5c (diff)
Merge pull request #1438 from IT-Can/form-helper-fix
Form helper fixes for issues triggered by 773ccc318f2769c9b7579630569b5d8ba47b114b
-rw-r--r--system/helpers/form_helper.php15
1 files changed, 9 insertions, 6 deletions
diff --git a/system/helpers/form_helper.php b/system/helpers/form_helper.php
index 410972187..984634315 100644
--- a/system/helpers/form_helper.php
+++ b/system/helpers/form_helper.php
@@ -325,7 +325,10 @@ if ( ! function_exists('form_dropdown'))
$selected = array($_POST[$name]);
}
- if ($extra !== '') $extra = ' '.$extra;
+ if ($extra != '')
+ {
+ $extra = ' '.$extra;
+ }
$multiple = (count($selected) > 1 && strpos($extra, 'multiple') === FALSE) ? ' multiple="multiple"' : '';
@@ -378,7 +381,7 @@ if ( ! function_exists('form_checkbox'))
{
$checked = $data['checked'];
- if ($checked === FALSE)
+ if ($checked == FALSE)
{
unset($data['checked']);
}
@@ -388,7 +391,7 @@ if ( ! function_exists('form_checkbox'))
}
}
- if ($checked === TRUE)
+ if ($checked == TRUE)
{
$defaults['checked'] = 'checked';
}
@@ -702,7 +705,7 @@ if ( ! function_exists('set_select'))
return '';
}
}
- elseif (($field === '' OR $value === '') OR ($field !== $value))
+ elseif (($field == '' OR $value == '') OR $field !== $value)
{
return '';
}
@@ -753,7 +756,7 @@ if ( ! function_exists('set_checkbox'))
return '';
}
}
- elseif (($field === '' OR $value === '') OR ($field !== $value))
+ elseif (($field == '' OR $value == '') OR $field !== $value)
{
return '';
}
@@ -806,7 +809,7 @@ if ( ! function_exists('set_radio'))
}
else
{
- if (($field === '' OR $value === '') OR ($field !== $value))
+ if (($field == '' OR $value == '') OR $field !== $value)
{
return '';
}