Commit fba2cdd4 authored by Asitha de Silva's avatar Asitha de Silva

Fix Foreach Parameters

parent 18539075
...@@ -45,7 +45,7 @@ Retrieving objects from the database is pretty much the same process as a mysqli ...@@ -45,7 +45,7 @@ Retrieving objects from the database is pretty much the same process as a mysqli
```php ```php
//$users = dbObject::table('users')->get(); //$users = dbObject::table('users')->get();
$users = user::get(); $users = user::get();
foreach (users as $u) { foreach ($users as $u) {
echo $u->login; echo $u->login;
} }
``` ```
...@@ -53,7 +53,7 @@ foreach (users as $u) { ...@@ -53,7 +53,7 @@ foreach (users as $u) {
## Using Where Condition And A Limit ## Using Where Condition And A Limit
```php ```php
$users = user::where("login", "demo")->get(Array (10, 20)); $users = user::where("login", "demo")->get(Array (10, 20));
foreach (users as $u) ... foreach ($users as $u) ...
``` ```
##Retrieving A Model By Primary Key ##Retrieving A Model By Primary Key
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment