summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--system/database/drivers/mssql/mssql_result.php1
-rw-r--r--system/database/drivers/mysql/mysql_result.php1
-rw-r--r--system/database/drivers/mysqli/mysqli_result.php1
-rw-r--r--user_guide_src/source/general/routing.rst4
4 files changed, 5 insertions, 2 deletions
diff --git a/system/database/drivers/mssql/mssql_result.php b/system/database/drivers/mssql/mssql_result.php
index ea3f8e4d1..b6e5f2b17 100644
--- a/system/database/drivers/mssql/mssql_result.php
+++ b/system/database/drivers/mssql/mssql_result.php
@@ -74,6 +74,7 @@ class CI_DB_mssql_result extends CI_DB_result {
public function list_fields()
{
$field_names = array();
+ mssql_field_seek($this->result_id, 0);
while ($field = mssql_fetch_field($this->result_id))
{
$field_names[] = $field->name;
diff --git a/system/database/drivers/mysql/mysql_result.php b/system/database/drivers/mysql/mysql_result.php
index 1ed2759b6..a2affcb58 100644
--- a/system/database/drivers/mysql/mysql_result.php
+++ b/system/database/drivers/mysql/mysql_result.php
@@ -89,6 +89,7 @@ class CI_DB_mysql_result extends CI_DB_result {
public function list_fields()
{
$field_names = array();
+ mysql_field_seek($this->result_id, 0);
while ($field = mysql_fetch_field($this->result_id))
{
$field_names[] = $field->name;
diff --git a/system/database/drivers/mysqli/mysqli_result.php b/system/database/drivers/mysqli/mysqli_result.php
index 4105f99f6..3fe05f9c5 100644
--- a/system/database/drivers/mysqli/mysqli_result.php
+++ b/system/database/drivers/mysqli/mysqli_result.php
@@ -74,6 +74,7 @@ class CI_DB_mysqli_result extends CI_DB_result {
public function list_fields()
{
$field_names = array();
+ $this->result_id->field_seek(0);
while ($field = $this->result_id->fetch_field())
{
$field_names[] = $field->name;
diff --git a/user_guide_src/source/general/routing.rst b/user_guide_src/source/general/routing.rst
index 2a0332088..ed21a6109 100644
--- a/user_guide_src/source/general/routing.rst
+++ b/user_guide_src/source/general/routing.rst
@@ -129,7 +129,7 @@ For those of you who don't know regular expressions and want to learn
more about them, `regular-expressions.info <http://www.regular-expressions.info/>`
might be a good starting point.
-..note:: You can also mix and match wildcards with regular expressions.
+.. note:: You can also mix and match wildcards with regular expressions.
Callbacks
=========
@@ -137,7 +137,7 @@ Callbacks
If you are using PHP >= 5.3 you can use callbacks in place of the normal
routing rules to process the back-references. Example::
- $route['products/([a-z]+)/edit/(\d+)'] = function ($product_type, $id)
+ $route['products/([a-zA-Z]+)/edit/(\d+)'] = function ($product_type, $id)
{
return 'catalog/product_edit/' . strtolower($product_type) . '/' . $id;
};