[TYPO3-project-formidable] Newby question

Jerome Schneider typo3dev at ameos.com
Tue Mar 18 18:19:35 CET 2008


Hi Albert,
Thanks for the feedback :)

You're right when saying that it's not optimal to use datahandler:DB 
with all rdt's readonly to display a record.

I also agree that the best way would be to improve the data layer, 
adding the ability to bind a box to a datasource, to create a local 
"data-context" if you see what I mean.

We thought about this already, but nothing came out for the moment.

something like:

<renderlet:BOX name="my-page-box">
	<datasource use="page" />
	<childs>
		<renderlet:TEXT name="title" />
		<renderlet:DATE name="crdate/>
		<!-- ... -->
	</childs>
</renderlet:BOX>



For the moment, there's another way to achieve this, if you're using a 
renderer:TEMPLATE; 2 steps:

1 - manually fetch the row from the DB and pass it to the renderer:TEMPLATE
2 - Use the template syntax to access data and display it in the html

I put an example here:

http://formidable.typo3.ug/features/template-engine/inject-data-in-the-template.html

Best regards,
Jerome Schneider







Albert van der Veen a écrit :
> Thanks Jerome,
> 
> That's how I had set it up, based on posts on this list, and works fine. 
> It feels like 'misusing' the 'edition' method though. Now you have to 
> have a datahandler:DB, although nothing is done with the data except 
> displaying it.
> It would make more sense to have something like the renderlet:LISTER, 
> that doesn't need a datahandler, only a datasource. The readonly also 
> wouldn't be necessary on each renderlet, as it would be assumed.
> 
> As I said, I have just started using Formidable (and loving it already), 
> so don't take this as a negative feedback, only wondering why it works 
> like this...
> 
> grtz,
> Albert
> 
> Jerome Schneider wrote:
>> Hi Albert,
>>
>> You may use a datahandler:DB with tablename and keyname properly set.
>>
>> To edit a particular uid with this, you'll have to pass it as the 
>> third argument of init() in your plugin code
>>
>> And renderlets should be set as readonly=true
>>
>> Best regards,
>> Jerome
>>
>>
>>


More information about the TYPO3-project-formidable mailing list