Can I create a template controller? |
[eluser]sorenchr[/eluser]
Hi I'm currently writing a site that uses ajax a lot. Sometimes my controllers only need to output ajax data, and this requires a lot of repeated code (formatting data, loading the same views etc.). So I'm wondering if there is a way to create a template controller that handles all this for me. Like: Code: <?php And the template Code: <?php
[eluser]Joseph Wensley[/eluser]
Phil Sturgeon has a blog post about extending controllers. http://philsturgeon.co.uk/news/2010/02/C...ing-it-DRY
[eluser]sorenchr[/eluser]
[quote author="Joseph Wensley" date="1298504831"]Phil Sturgeon has a blog post about extending controllers. http://philsturgeon.co.uk/news/2010/02/C...ing-it-DRY[/quote] Thanks! Interesting stuff. |
Welcome Guest, Not a member yet? Register Sign In |