laravel 4.2 - Eloquent model User doesn't returns the right array -


i have trouble in making site page on every user displayed in order manage them.

the users displayed name, email, permission , links modify, reset password , delete them on other page

i made function in controller page "manage-user":

public function getmanageusers(){     $users = user::all();     var_dump($users);     return view::make('usersmanagement.manage-users')->with('users', '$users'); } 

but result of var_dump() actually:

    object(illuminate\database\eloquent\collection)[163]   protected 'items' =>          array (size=3)           0 =>          object(user)[159]           protected 'table' => string 'users' (length=5)           protected 'hidden' =>              array (size=2)               ...           protected 'connection' => null           protected 'primarykey' => string 'id' (length=2)           protected 'perpage' => int 15           public 'incrementing' => boolean true           public 'timestamps' => boolean true           protected 'attributes' =>              array (size=9)               ...           protected 'original' =>              array (size=9)               ...               protected 'relations' =>              array (size=0)               ...           protected 'visible' =>              array (size=0)               ...           protected 'appends' =>              array (size=0)               ...           protected 'fillable' =>              array (size=0)               ...           protected 'guarded' =>              array (size=1)               ...           protected 'dates' =>              array (size=0)               ...           protected 'touches' =>              array (size=0)               ...           protected 'observables' =>              array (size=0)               ...           protected 'with' =>              array (size=0)               ...           protected 'morphclass' => null           public 'exists' => boolean true 

here model if helps :

<?php  use illuminate\auth\usertrait; use illuminate\auth\userinterface; use illuminate\auth\reminders\remindabletrait; use illuminate\auth\reminders\remindableinterface;  class user extends eloquent implements userinterface, remindableinterface {      use usertrait, remindabletrait;      /**      * database table used model.      *      * @var string      */     protected $table = 'users';      /**      * attributes excluded model's json form.      *      * @var array      */     protected $hidden = array('password', 'remember_token'); } 

i don't understand problem since used line of code retrieve every data of of database , worked db's indexes.

i'm lost on situation , don't know do. welcomed. in advance.

damien


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -