Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Update README.md

Fixed MYSQLI_FETCH_ASSOC to MYSQLI_ASSOC
  • Loading branch information...
commit da03c9eaec386bd8f30919d0b33be4e91eec5c8c 1 parent 14a36fe
@jasny authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 README.md
View
4 README.md
@@ -26,8 +26,8 @@ the file from the 'src' folder.
$result = DB::conn()->query("SELECT * FROM foo WHERE type = ?", $type);
$result = DB::conn()->query("SELECT * FROM foo WHERE type = ? AND cat IN ?", $type, array(1, 7));
- $items = DB::conn()->fetchAll("SELECT id, name, description FROM foo WHERE type = ?", MYSQLI_FETCH_ASSOC, $type);
- $item = DB::conn()->fetchOne("SELECT * FROM foo WHERE id = ?", MYSQLI_FETCH_ASSOC, $id);
+ $items = DB::conn()->fetchAll("SELECT id, name, description FROM foo WHERE type = ?", MYSQLI_ASSOC, $type);
+ $item = DB::conn()->fetchOne("SELECT * FROM foo WHERE id = ?", MYSQLI_ASSOC, $id);
$names = DB::conn()->fetchColumn("SELECT name FROM foo WHERE type = ?", $type);
$list = DB::conn()->fetchPairs("SELECT id, name FROM foo WHERE type = ?", $type);
$name = DB::conn()->fetchValue("SELECT name FROM foo WHERE id = ?", $id);
Please sign in to comment.
Something went wrong with that request. Please try again.