I think it should be something like this:
in your views create the views that you need, ex: game1.ctp,
game2.ctp, etc...
in controller:
if($var==1) $this->render('game1');
if($var==2) $this->render('game2');
etc...On Jul 23, 10:49 pm, Michael Gaiser <[email protected]> wrote: > So I am working on a site that would display characters from several > different games, many of which share the same types of attributes but just > call them differently. I have a variable setup to tell me which game we are > currently dealing with so my question is this, do I just have the view > contain multiple if statements and set it up like a large switch, or is it > possible to have the controller call a different view depending on that > variable as would be my preference. Thanks. > > ~Michael -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php
