Welcome Guest, Not a member yet? Register   Sign In
Object of class CI_DB_mysql_result could not be converted to string [SOLVED]
#1

[eluser]Asinox[/eluser]
Hi guys, im trying to count register, but i have the next error:
Code:
A PHP Error was encountered
Severity: 4096
Message: Object of class CI_DB_mysql_result could not be converted to string
Filename: controllers/site.php
Line Number: 41

my code
Code:
function columnasTiposBares(){
             $tipos = $this->modsite->tiposBaresColumna();
             foreach($tipos as $tipo):
             $contando = $tipo->tipo;
             $tip[] =  anchor('site/lugares/'.$tipo->tipo,$tipo->tipo)."->".$this->db->query('SELECT COUNT(tipo) as total from negocios where tipo = "'.$tipo->tipo.'"');
             endforeach;
         return  $this->table->make_columns($tip, 3);
      }

What is wrong guys?

Thanks


Messages In This Thread
Object of class CI_DB_mysql_result could not be converted to string [SOLVED] - by El Forum - 03-10-2009, 11:36 AM



Theme © iAndrew 2016 - Forum software by © MyBB