Views and PHP Code

#6
[eluser]plainas[/eluser]
From what I red out there in the forums, most of the people simple jam loops into the views. I personally find myself thinking how 'unMVC' those loops are.

There are neater solutions in my opinion.

Write a helper function to render the table in a CSS friendly way, then push it to the view through a variable. IMHO, the layout of a table is not part of the view, its looks are, but that you can control by simply using CSS.

Other solution is writing a view only to render the table, then fetch that view output and pass it to another view. I guess this is the best solution.


Messages In This Thread
Views and PHP Code - by El Forum - 02-01-2009, 12:25 PM
Views and PHP Code - by El Forum - 02-01-2009, 01:03 PM
Views and PHP Code - by El Forum - 02-01-2009, 01:54 PM
Views and PHP Code - by El Forum - 02-01-2009, 01:57 PM
Views and PHP Code - by El Forum - 02-01-2009, 02:11 PM
Views and PHP Code - by El Forum - 02-01-2009, 07:36 PM
Views and PHP Code - by El Forum - 02-01-2009, 07:48 PM
Views and PHP Code - by El Forum - 02-01-2009, 08:49 PM
Views and PHP Code - by El Forum - 02-01-2009, 09:00 PM
Views and PHP Code - by El Forum - 02-01-2009, 10:15 PM
Views and PHP Code - by El Forum - 02-01-2009, 10:32 PM
Views and PHP Code - by El Forum - 02-01-2009, 11:20 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.