In actual, we can't get the desired output since we can't do the
sequential outputs, call pass().
ok, so is this what you mean?
VIEW
Header 1: Fruits are here. <br />
<?php
foreach ($fruits as $fruit) {
echo "$fruit<br />";
}
?>
Header 2: Animals are here. <br />
<?php
foreach ($animals as $animal) {
echo "$animal<br />";
}
?>
Header 3: Colors are here. <br />
<?php
foreach ($colors as $color) {
echo "$color<br />";
}
?>
CONTROLLER:
<?php
class TestsController extends AppController {
var $name = 'Tests';
function pass() {
$this->set('fruits', $this->Test->myfunction(1));
$this->set('animals', $this->Test->myfunction(2));
$this->set('colors', $this->Test->myfunction(3));
}
}
--
TJ Singleton
?>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---