XPAGE : Get HTML code of rich text field in javascript

Hello,

I have an xpage and I use the Rich Text component to display the html code on my page.

But I would like to make modifications on the fly on juste before the display of the html.

The binding I use is :

rub.PAG_TR_Z1

I have change it to a javascript binding with the following code :

var htmlCode = rub.getItemValueString(“PAG_TR_Z1”);

But htmlCode is empty because PAG_TR_Z1 is stored as a Mime/Html data. Same result if I use getItemValue.

So is there a way to get access to the html code in server side javascript ?

Subject: does “getValue” work

I was looking at a different issue, but needed to get content in a rich text field. (Testing if field was empty, when either Richtext or MIME). I had also tried getItemValue and getItemValueString without luck, but then found getValue to resolve my issue.

Hope this helps.