[Typo3] creating a basic extension : how can i add a select/option form element in the BE/plugin
typo3-ml at w3tex.com
typo3-ml at w3tex.com
Mon Dec 5 12:27:39 CET 2005
hmmm... OK thanks
I'll try to edit this tca.php
On 5 déc. 05, at 12:15, Jochen Rieger wrote:
> Hi typo3-ml (interesting name btw ;) ),
>
> I think tca.php is your friend.
>
> Something like this:
>
> "yourDbField" => Array (
> "exclude" => 1,
> "label" =>
> "LLL:EXT:yourExtension/
> locallang_db.php:tx_yourExtension.yourLocalLangLabel",
>
> "config" => Array (
> "type" => "select",
> "items" => Array (
>
> Array("LLL:EXT:yourExtension/
> locallang_db.php:tx_yourExtension.yourLocalLangLabel.option.0",
> "value1"),
>
> Array("LLL:EXT:yourExtension/
> locallang_db.php:tx_yourExtension.yourLocalLangLabel.option.1",
> "value2"),
>
> Array("LLL:EXT:yourExtension/
> locallang_db.php:tx_yourExtension.yourLocalLangLabel.option.2",
> "value3"),
> ),
> "size" => 1,
> "maxitems" => 1,
> )
> ),
>
> --------
>
> of cause you can also fill in hard coded labels insteand of using your
> locallang_db.php
>
> Hope that'll help.
>
> Not to forget that also you have to have your fields configured in
> ext_tables.sql and if needed ext_tables.php.
>
> Cheers,
> Jochen
>
> typo3-ml at w3tex.com wrote:
>> Hi,
>>
>> I just followed the "creating a basic extension" PDF tutorial.
>>
>> everything works OK.
>>
>>
>> now I need to add in the Back end / plugin form
>> a <SELECT> form element
>> using selectable items provided by a database query.
>>
>> something like this
>> <select name="categories">
>> <option value="1">skate</option>
>> <option value="1">bike</option>
>> ...
>> </select>
>>
>> which file should I modify to add this form element in the BE/
>> plugin ?
>>
>>
>> please help ! thanks !!
>>
>>
>
> --
> :: innovative it-strategies ::
> :: ::
> :: www.connecta.ag ::
> _______________________________________________
> Typo3-english mailing list
> Typo3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>
More information about the TYPO3-english
mailing list