[TYPO3-project-formidable] modalbox: change child renderlet:BOX with oMajixEvent parameters

Jerome Schneider typo3dev at ameos.com
Mon Mar 16 10:58:28 CET 2009


Hi Hauke !

In snippets 92 and 93, we were using an external php file (the 
codeBehind). In the php of this codebehind, to refer to the formidable 
main object, you have to specify $this->oForm

But, when in a userobj directly in the xml, the main Formidable object 
is pointed by $this directly (because in this case, it's formidable that 
holds your php-code, and not an external codeBehind object)

So, to get the parameters in the codeBehind, we were refering to
$this->oForm->oMajixevent->getParams();

But in the userobj, you have to ask for:
$this->oMajixEvent->getParams();


Now for the second part, changing the HTML of your box, there are 2 ways:

First one: using majixRepaint(), as demonstrated in snippets 92&93
Second one: using majixSetHtml()

In other words:

* if you need to 'refresh' the display of your box, while keeping your 
renderlets inside, you need to use majixRepaint(), as repaint re-renders 
the renderlets and send te new HTML via ajax to refresh the display.

* if you simply need to set a message inside a box, use majixSetHtml() 
on the box.

I hope I made myself understandable, and let me know if not :)

Jerome

Hauke Hain a écrit :
> Hi,
> 
> I have a modalbox and in this modalbox a renderlet box where I want to 
> change the <html>-Content dynamically.
> To do so I tried to use a userobj php with 
> $this->oForm->oMajixEvent->getParams(); but that does not work 
> (non-object error).
> Do you know hot to get the params there or how to change the content of 
> the box from the codebehind of the modalbox like used in snippets 92/93?
> document.getElementById('id....').innerHTML= does not work. PHP says 
> that the '=' is to much...
> 
> I am a little bit confused.
> 
> Thank you for help in advance.
> 
> Regards,
> Hauke
> 
> 


More information about the TYPO3-project-formidable mailing list