I'm stuck :( I have been using ModelBaker to create my app and it went
extremely well until I wanted to start customising the code. I'm
learning CakePHP and MVC at the moment, but I've exceeded my curent
knowledge (which is pretty easy at the moment). Anyway, I've been
trying to customise the root of my homepage with code like this:
<?php echo $form->create('Restaurant'); ?>
<div id="gridWrapper">
The home page ...
<table id="datagrid">
<tbody>
<?php foreach ($restaurants as $restaurant): ?>
<tr>
<td class="name"><?php echo $restaurant['Restaurant']
['name']; ?></td>
<td class="address_1"><?php echo $restaurant
['Restaurant']['address_1']; ?></td>
<td class="address_2"><?php echo $restaurant
['Restaurant']['address_2']; ?></td>
<td class="city"><?php echo $restaurant['Restaurant']
['city']; ?></td>
<td class="state"><?php echo $restaurant['Restaurant']
['state']; ?></td>
<td class="zip"><?php echo $restaurant['Restaurant']
['zip']; ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
but it doesn't work :( . It shows the "The home page ... " message
and that's it.
What am I missing ?
What do I need to code to make it work ?
Where can I read about this ?
Cheers,
Chris :)
--~--~---------~--~----~------------~-------~--~----~
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