Hi There,
I have started a new project at work today and a fellow developer has asked me to look into changing the way I work and implementing objects into my views to I can do checks within my view using the object.
To me this seems wrong, as surely this is the work of the Model and/or controller? Or am I wrong? I assume he is wanting me to implement something like this?
<?php if($user->can()) : ?>
Hello You can do this
<? endif; ?>
$user would be the object.
Is this possible? Is it the right way to do things? How would I do this?