I would never/rarely do what Cliff describes. I generally put as little 
logic into the views as possible. That is totally perfectly fine with 
Web2py.

But it's nice to have full Python available. It's basically the best of 
both worlds. If you need to have the templating literally forbid you from 
using too much logic, then maybe Web2py isn't the right framework. But that 
seems bizarre to me.


On Friday, September 7, 2012 12:21:30 PM UTC-7, luckysmack wrote:
>
> But see, to me, now that's putting HTML in the controller. Which I see as 
> a negative. Ideally I would pass the data to the view and use a foreach 
> over the data contents. And for marking a field as red, I would put some 
> metadata into the data sent to the view. I would just test if vacant was 
> true, and if so, change style. This way there's no hidden HTML 
> tags/structure from a designers template file. 
> On Sep 7, 2012 12:11 PM, "Andrew W" <awill...@gmail.com <javascript:>> 
> wrote:
>
>> Good example Cliff.
>>
>> --
>>
>>
>>
>>  

-- 



Reply via email to