[TYPO3-ect] new version of smartyView

Steffen Kamper steffen at sk-typo3.de
Mon Oct 22 11:54:02 CEST 2007


"Simon Tuck" <stu at rtpartner.ch> schrieb im Newsbeitrag 
news:mailman.1.1193041485.8358.typo3-team-extension-coordination at lists.netfielders.de...
> Hi Steffen,
>
> I have some feedback for the smartyView class:
>
> I have a minor issue with the render function:
> The parameter sent to the display method ($this->pathToTemplates . '/' . 
> $view) isn't wrong, but strictly speaking you shouldn't need to define the 
> templates directory, the latest version of rtp_smarty will use the 
> pathToTemplates declared in the controller. At best it's redundant, at 
> worst running $view->render('my/other/path/myTemplate.tpl.html') will 
> fail.
>
> I have a basic issue regarding the printAsUrl method in the smartyView 
> class. It's a matter of opinion, but I think it makes more sense to use 
> the Smarty tags {url} or {link}label{/link} than to start using PHP 
> functions. The tags described above are provided via Smarty plugins which 
> implement TYPO3 features (i.e. the {link} tag implements the typolink 
> function). I think it would make sense if we could agree on the approach 
> here: do we include methods such as printAsUrl in the smartyView class or 
> do we implement Smarty plugins that provide the equivalent functionality 
> as tags in Smarty. What do you think?
>
> Cheers,
> Simon
>

Hi Simon,

i didn't examined the new version of rpt_smarty yet.
If path is set in controller this function is not needed, but what happens 
if not? the idea was in general to set, but you're right, settings should be 
done in controller.

I also prefer the smarty tags - remember that the smartyView was a very 
basic class to get a start.

I will look to your extension to see how you did the job ;-)

vg  Steffen 




More information about the TYPO3-team-extension-coordination mailing list