[TYPO3-project-formidable] Listbox disabled - with diff
Luc Muller
l.mul-nospam-ler at ameos.com
Mon Dec 22 16:08:06 CET 2008
Thanks for the patch :)
You can achieve the same sort of thing using a custom.
this is available on (I think) all the renderlets. (if not obsolete in
last revisions)
You can then write : <custom>disabled="disabled"</custom>
but you can specify any other html attributes you want, thus can be
useful for thing such as rel="" or anythink you'de like to have as
attributes.
Luc =:0)
Christof Rodejohann a écrit :
> Hello,
>
> i would like to suggest a possible switch to disable a Listbox
> renderlet (The HTML option "disable = true".). If you decide that this
> would be a good idea: Here is a diff against the latest SVN version
> 287:
>
> +++ ..\formidable\api\base\rdt_listbox\api\class.tx_rdtlistbox.php Sa
> Dez 20 23:12:47 2008
> @@ -29,6 +29,11 @@
> }
> }
>
> + $sDisabled = "";
> + if($this->_defaultFalse("/disabled") === TRUE) {
> + $sDisabled = "disabled=\"true\" ";
> + }
> +
> $aSelectedCaptions = array();
> $bSelected = FALSE;
>
> @@ -64,7 +69,7 @@
> $sClass = $this->_getClass($aItem);
> $sStyle = $this->_getStyle($aItem);
>
> - $aHtml[] = "<option value=\"" . $aItem["value"] . "\" " .
> $sSelected . $sClass . $sStyle . $sCustom . ">" . $sCaption .
> "</option>";
> + $aHtml[] = "<option value=\"" . $aItem["value"] . "\" " .
> $sSelected . $sDisabled . $sClass . $sStyle . $sCustom . ">" .
> $sCaption . "</option>";
> }
>
> reset($aHtml);
>
> Regards,
> Christof
>
--
*Luc Muller*
/Web Developper/
/Formidable - Rapid Application Developpement Framework for Typo3
<http://formidable.typo3.ug>/
/Typo3 Ameos <http://www.ameos.com>/
More information about the TYPO3-project-formidable
mailing list