Added is_cli_request() method to documentation for Input class.
diff --git a/system/helpers/form_helper.php b/system/helpers/form_helper.php
index 5323097..8aa788c 100644
--- a/system/helpers/form_helper.php
+++ b/system/helpers/form_helper.php
@@ -49,11 +49,15 @@
$attributes = 'method="post"';
}
+ // If an action is not a full URL then turn it into one
if ($action && strpos($action, '://') === FALSE)
{
$action = $CI->config->site_url($action);
}
+ // If no action is provided then set to the current url
+ $action OR $action = $CI->config->site_url($CI->uri->uri_string());
+
$form = '<form action="'.$action.'"';
$form .= _attributes_to_string($attributes, TRUE);