[TYPO3-project-formidable] Renderlet::Radiobutton: How to fetch the value?
Michael Niemeyer
michael.niemeyer at 4tuna-it.de
Wed Sep 5 16:20:14 CEST 2007
In a test configuration there are 4 elements: an input field, two radio
buttons, an action button and at last a window to show the information.
It works fine ff i refer only to the textvalue. But after adding the
radiovalue to the params the window will not be shown anymore.
The solution may be simple, but my question is:
Is it possible to refer to the value of a radiobutton by a button and
if, how it must be done?
Some code follows to explain it further:
// Item 1 is an input field
<renderlet:TEXT name="textvalue">
<name>Textvalue</name>
</renderlet:TEXT>
// Item 2 is a group of two radio buttons
<renderlet:RADIOBUTTON name="radiovalue">
<label>Radiovalue</label>
<data>
<items>
<item caption="On" value="on"/>
<item caption="Off" value="off"/>
</items>
</data>
</renderlet:RADIOBUTTON>
// Item 3 is a button
<renderlet:BUTTON name="buttonname" label="show info" >
<onclick runat="ajax" cache="false" params="textvalue,
radiovalue">
<userobj>
<php><![CDATA[
$aParams = array_pop(func_get_args());
return array(
$this->aORenderlets["resultinfo"]->majixShowBox(),
$this->aORenderlets["result"]->majixReplaceData(print_r($aParams,true))
);
]]></php>
</userobj>
</onclick>
</renderlet:BUTTON>
// Item 4 is an overlay box for showing the information
<renderlet:MODALBOX name="resultinfo">
<childs>
<renderlet:BOX name="result" mode="b" />
<renderlet:BUTTON name="resultinfo_close" label="close">
<onclick runat="client">
<userobj>
<php><![CDATA[
return
$this->aORenderlets["resultinfo"]->majixCloseBox();
]]></php>
</userobj>
</onclick>
</renderlet:BUTTON>
</childs>
</renderlet:MODALBOX>
More information about the TYPO3-project-formidable
mailing list