[TYPO3-project-formidable] $aParams is empty?
Asbjørn Morell
atmorell at gmail.com
Tue Apr 3 12:35:24 CEST 2007
Hello.
I am still learning formidable.. I like it very much! the code is clean -
when xml, php and html is separated. However I have a small problem that I
hope that any of you can help me with. What I would like to do is ad a
delete image link to the step4 pi. So I looked at the step4.xml file and
copied the update renderlet and modified it so it will set the image filed
to nothing (see below) However my variable $iUid is empty when called in
step2.xml ? ? I just can't figure out what is wrong. I did some testing and
it seems that the $aParams array is empty on step2.xml
Any help is most welcome.
Best regards.
Asbjørn Morell.
<renderlet:LINK name="lnk_delete_image" activelistable="true">
<label>Delete image</label>
<onclick
runat="server"
params="uid"
confirm="Are you sure you want to delete this image ?"
when="start"
>
<userobj>
<php><![CDATA[
$aParams = func_get_args();
$iUid = $aParams[1]["uid"];
$updateFields = array('image' => '');
$GLOBALS["TYPO3_DB"]->exec_UPDATEquery(
"tx_ameost3con06_car",
"uid='" . $iUid . "'",
$updateFields
);
]]></php>
</userobj>
</onclick>
</renderlet:LINK>
More information about the TYPO3-project-formidable
mailing list