Hi
I am trying to attac a visual-editor (Whizzywig from Unverse) to a textArea field. It works fine when I type directly into the input box. The problem starts when I try to paste text from any other editor (including Notepad unformatted) into it. Ofbiz throws an error "< greater and less-than >" symbols not allowed when it tries to validate the field. I have tried various clean it tools - but it does not work. The Unverse website is not helpful either. Any ideas? Regards Gavin |
The editor lets you see how it will be shown in a webrowser, however
the actual paste is the html code of what you see. if you look at the html code you will see "< greater and less-than >". I am not sure where you are pasting into ofbiz so can not comment further. Gavin Mabie sent the following on 9/10/2011 9:53 AM: > Hi > > > > I am trying to attac a visual-editor (Whizzywig from Unverse) to a textArea > field. It works fine when I type directly into the input box. The problem > starts when I try to paste text from any other editor (including Notepad > unformatted) into it. Ofbiz throws an error "< greater and less-than >" > symbols not allowed when it tries to validate the field. I have tried > various clean it tools - but it does not work. The Unverse website is not > helpful either. Any ideas? > > > > Regards > > > > Gavin > > |
In reply to this post by Gavin Mabie
Hi Gavin:
Not sure if this is your problem or not, but I had a similar issue with email message content. The solution was to change the attribute(s) on the Service(s) used from something like: <attribute name="textArea" type="String" mode="IN" optional="true" allow-html="safe"/> to: <attribute name="textArea" type="String" mode="IN" optional="true" allow-html="any"/> There was something in the pasted text (a hidden character or something that the OFBiz HTML Service validation didn't like.) Of course, this assumes that you are calling a Service on the backend and not processing the form some other way :-) So, to make this change you have to figure out which Service is being called when your form's textarea is being processed on the backend. Best of luck. Ruth On 9/10/11 12:53 PM, Gavin Mabie wrote: > Hi > > > > I am trying to attac a visual-editor (Whizzywig from Unverse) to a textArea > field. It works fine when I type directly into the input box. The problem > starts when I try to paste text from any other editor (including Notepad > unformatted) into it. Ofbiz throws an error "< greater and less-than>" > symbols not allowed when it tries to validate the field. I have tried > various clean it tools - but it does not work. The Unverse website is not > helpful either. Any ideas? > > > > Regards > > > > Gavin > > |
Administrator
|
If it's at the UI level and you use form widget, try to use encode-output="true"
There are examples OOTB Jacques From: "Ruth Hoffman" <[hidden email]> > Hi Gavin: > Not sure if this is your problem or not, but I had a similar issue with > email message content. The solution was to change the attribute(s) on > the Service(s) used from something like: > > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="safe"/> > to: > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="any"/> > > There was something in the pasted text (a hidden character or something > that the OFBiz HTML Service validation didn't like.) > > Of course, this assumes that you are calling a Service on the backend > and not processing the form some other way :-) > > So, to make this change you have to figure out which Service is being > called when your form's textarea is being processed on the backend. > > Best of luck. > Ruth > > On 9/10/11 12:53 PM, Gavin Mabie wrote: >> Hi >> >> >> >> I am trying to attac a visual-editor (Whizzywig from Unverse) to a textArea >> field. It works fine when I type directly into the input box. The problem >> starts when I try to paste text from any other editor (including Notepad >> unformatted) into it. Ofbiz throws an error "< greater and less-than>" >> symbols not allowed when it tries to validate the field. I have tried >> various clean it tools - but it does not work. The Unverse website is not >> helpful either. Any ideas? >> >> >> >> Regards >> >> >> >> Gavin >> >> |
In reply to this post by Ruth Hoffman-2
Thanks Ruth.
I added allow-html="safe" to the attribute element and that resolved the issue. Regards Gavin -----Original Message----- From: Ruth Hoffman [mailto:[hidden email]] Sent: 10 September 2011 09:33 PM To: [hidden email] Subject: Re: Whizzywig Hi Gavin: Not sure if this is your problem or not, but I had a similar issue with email message content. The solution was to change the attribute(s) on the Service(s) used from something like: <attribute name="textArea" type="String" mode="IN" optional="true" allow-html="safe"/> to: <attribute name="textArea" type="String" mode="IN" optional="true" allow-html="any"/> There was something in the pasted text (a hidden character or something that the OFBiz HTML Service validation didn't like.) Of course, this assumes that you are calling a Service on the backend and not processing the form some other way :-) So, to make this change you have to figure out which Service is being called when your form's textarea is being processed on the backend. Best of luck. Ruth On 9/10/11 12:53 PM, Gavin Mabie wrote: > Hi > > > > I am trying to attac a visual-editor (Whizzywig from Unverse) to a textArea > field. It works fine when I type directly into the input box. The problem > starts when I try to paste text from any other editor (including Notepad > unformatted) into it. Ofbiz throws an error "< greater and less-than>" > symbols not allowed when it tries to validate the field. I have tried > various clean it tools - but it does not work. The Unverse website is not > helpful either. Any ideas? > > > > Regards > > > > Gavin > > |
Have a look at the solution from Jacques....there the ofbiz selected
editor is used...why add something which is already there? On Sun, 2011-09-11 at 06:27 +0200, Gavin Mabie wrote: > Thanks Ruth. > > I added allow-html="safe" to the attribute element and that resolved the > issue. > > Regards > > Gavin > > -----Original Message----- > From: Ruth Hoffman [mailto:[hidden email]] > Sent: 10 September 2011 09:33 PM > To: [hidden email] > Subject: Re: Whizzywig > > Hi Gavin: > Not sure if this is your problem or not, but I had a similar issue with > email message content. The solution was to change the attribute(s) on > the Service(s) used from something like: > > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="safe"/> > to: > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="any"/> > > There was something in the pasted text (a hidden character or something > that the OFBiz HTML Service validation didn't like.) > > Of course, this assumes that you are calling a Service on the backend > and not processing the form some other way :-) > > So, to make this change you have to figure out which Service is being > called when your form's textarea is being processed on the backend. > > Best of luck. > Ruth > > On 9/10/11 12:53 PM, Gavin Mabie wrote: > > Hi > > > > > > > > I am trying to attac a visual-editor (Whizzywig from Unverse) to a > textArea > > field. It works fine when I type directly into the input box. The > problem > > starts when I try to paste text from any other editor (including Notepad > > unformatted) into it. Ofbiz throws an error "< greater and less-than>" > > symbols not allowed when it tries to validate the field. I have tried > > various clean it tools - but it does not work. The Unverse website is not > > helpful either. Any ideas? > > > > > > > > Regards > > > > > > > > Gavin > > > > > -- Ofbiz on twitter: http://twitter.com/apache_ofbiz Alternative ofbiz website: http://www.ofbiz.info http://www.antwebsystems.com : Quality services for competitive rates. |
Hi Hans
I am using HtmlEdit under "/images/htmledit" which is already included in ofbiz - not adding something new. Gavin -----Original Message----- From: Hans Bakker [mailto:[hidden email]] Sent: 11 September 2011 07:26 AM To: [hidden email] Subject: RE: Whizzywig Have a look at the solution from Jacques....there the ofbiz selected editor is used...why add something which is already there? On Sun, 2011-09-11 at 06:27 +0200, Gavin Mabie wrote: > Thanks Ruth. > > I added allow-html="safe" to the attribute element and that resolved the > issue. > > Regards > > Gavin > > -----Original Message----- > From: Ruth Hoffman [mailto:[hidden email]] > Sent: 10 September 2011 09:33 PM > To: [hidden email] > Subject: Re: Whizzywig > > Hi Gavin: > Not sure if this is your problem or not, but I had a similar issue with > email message content. The solution was to change the attribute(s) on > the Service(s) used from something like: > > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="safe"/> > to: > <attribute name="textArea" type="String" mode="IN" optional="true" > allow-html="any"/> > > There was something in the pasted text (a hidden character or something > that the OFBiz HTML Service validation didn't like.) > > Of course, this assumes that you are calling a Service on the backend > and not processing the form some other way :-) > > So, to make this change you have to figure out which Service is being > called when your form's textarea is being processed on the backend. > > Best of luck. > Ruth > > On 9/10/11 12:53 PM, Gavin Mabie wrote: > > Hi > > > > > > > > I am trying to attac a visual-editor (Whizzywig from Unverse) to a > textArea > > field. It works fine when I type directly into the input box. The > problem > > starts when I try to paste text from any other editor (including Notepad > > unformatted) into it. Ofbiz throws an error "< greater and less-than>" > > symbols not allowed when it tries to validate the field. I have tried > > various clean it tools - but it does not work. The Unverse website is not > > helpful either. Any ideas? > > > > > > > > Regards > > > > > > > > Gavin > > > > > -- Ofbiz on twitter: http://twitter.com/apache_ofbiz Alternative ofbiz website: http://www.ofbiz.info http://www.antwebsystems.com : Quality services for competitive rates. |
Free forum by Nabble | Edit this page |