1

We have IBM WCM 8.5, and created content which contains Rich Text component in AT field.

I want to check whether the value of Rich Text is empty or not in one of my Menu Component.

I have tried to use "IfEmpty Plugin Component", but it doesn't work.

If any one have solution to this, it is of great help to me.

Mohammad Ashfaq
  • 1,333
  • 2
  • 14
  • 38

2 Answers2

2

I have tried using Plugin:ifEmpty in WebSphere Portal 8.5 and they worked fine with Rich Text Editors.

This was the code that I used in the presentation template:-

 [Plugin:ifEmpty value="[Element context='current' type='content' key='richText']"]Empty![/Plugin:ifEmpty]
 [Plugin:ifNotEmpty value="[Element context='current' type='content' key='richText']"]Not Empty![/Plugin:ifNotEmpty]

It worked pretty well and responded appropriately.

May be you need to update to the latest fix pack. The other possibility would be that you inadvertently put some value in the rich text editor in the authoring template and all contents created from it took this value. Check the source of the rich text editor to make sure that it is empty.

Raef Kandil
  • 307
  • 1
  • 12
  • The source of empty rich text editor contains "

     

    " value, and hence it is not working. We have not assign default value to elements in AT.
    – Mohammad Ashfaq Aug 20 '15 at 06:01
  • For me this is not the case, are you sure you updated the Websphere Portal to the latest fix pack? Are you using the default rich text editor of the Portal? Did you try ifEquals instead? – Raef Kandil Aug 20 '15 at 17:35
  • I am using portal 8.5 with no fix packs, and I have tries all possible ways. It is possible that they have fixed this issue in one of the fix pack. – Mohammad Ashfaq Aug 21 '15 at 06:43
0

This is known issue in the Textbox.io editor which comes with IBM Portal 8.5. When its empty it gives the '<p>&nbsp;</p>' tags. We are facing the same issue. We are using Portal 8.5 CF 11