How do I select all records from my table in my ossn website ?

sunny sunny Posted in Technical Support 9 years ago

How do I select all records from my database table on my website ?

and after that i want to use while loop with fetch assoc function to get result in associative array.

Replies
Indonesian Arsalan Shah Replied 9 years ago

Please take a look : OssnDatabase Class Reference

You can use following code:

$Database = new OssnDatabase;
$Data = array(
     "from" => "My Table",
     "wheres" => array("something=xxx"),
);
$MyResult = $Database->select($Data, true);
while($MyResult){
     xxxxx
}