[eluser]Unknown[/eluser]
Hi!
I need to add Data to the View.
I know i can make it with this:
Code:
$this->load->view('someview', $data);
I had used it sometimes, but now, i cant solve the problem...
Can i somehow watch, what data-s i have in the view?
So, i need to list all the users in my database.
i have this:
Code:
$usersdb=$this->User_model->getUsers();
then $userdb looks like this:
Code:
array(3) {
[0]=> object(stdClass)#19 (2) {
["id"]=> "1"
["felhasznalonev"]=> "Koli"
}
[1]=> object(stdClass)#20 (2) {
["id"]=> string(1) "2"
["felhasznalonev"]=> string(6) "Jane"
}
[2]=> object(stdClass)#21 (2) {
["id"]=> string(1) "3"
["felhasznalonev"]=> string(4) "Mary"
}
}
How can i get the user-name and the id-pairs in the view?
I tried it in a lot of way, but it never worked...
Thanks:Koli