I have problem with foreach loop and inner join on php. I have two tables: toners and printers. And code:
$toner = $this->_db->execute('SELECT TONERS.NAME, PRINTERS.NAME, TONERS.CONTRACTORS FROM TONERS INNER JOIN PRINTERS ON TONERS.ID_PRINTERS=PRINTERS.ID;')
foreach ($toner as $toners) {
//here is the html table with results
}
receives an error: Warning: Invalid argument supplied for foreach(). I'll add that on the query without 'Inner join' everything works fine ...
Anyone have an idea? Please...