Ver Mensaje Individual
  #7 (permalink)  
Antiguo 11/06/2014, 09:35
Avatar de Italico76
Italico76
 
Fecha de Ingreso: abril-2007
Mensajes: 3.303
Antigüedad: 17 años, 1 mes
Puntos: 292
Respuesta: Problema con imprimir Objeto

Entonces.. define un __toString() en Alumnos :)

Código PHP:
Ver original
  1. public function __toString()
  2.     {
  3.          return "{$this->_nombre} ({$this->_edad} años) de {$this->_carrera}\n";
  4.     }
__________________
Salu2!