delete ['User'] and it works^^
On 4 Jul., 18:58, Tomfox Wiranata <tomfox.wiran...@gmail.com> wrote:
> hi,
>
> i try to retrieve user data and echo it in a view.
>
> my view:
> <table>
> <tr>
> <th>name</th>
>
> </tr>
>
> <?php foreach ($users as $user): ?>
>
> <tr>
> <td><?php echo $user['User']['firstname']; ?></td>
> <<<<<<<<<<<<<<<<< line 25 !!!!
> </tr>
> <?php endforeach; ?>
>
> </table>
>
> controller:
> function profile()
> {
> $this->set('users', $this->User->findByUsername($this->Session->read('User.username')));
>
> }
>
> its drivin me nuts....i dont think i did sth different from the blog
> example ??
>
> thx so much
>
> btw: the sql-statement is correct. it returns the value i need.....
Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
No comments:
Post a Comment