5

Has anyone experienced an issue with disableOutputTag property where if you disable output tag for a computed field control inside a repeat control and have ssjs computed content inside that tag, it won't compute the content? Is disableOutputtag property only meant to work with static content inside a repeat control or is it a bug?

pipalia
  • 911
  • 1
  • 12
  • 46
  • 1
    I also noticed such an issue with the disableoutputtag that in some situations it behaves like the 'rendered' property. Unfortunatly i couldn't reproduce the issue. – jjtbsomhorst Mar 14 '12 at 12:06
  • 1
    I don't know whether its a bug or not, but you can emulate the behavior of disableOutputTag by removing the ID attribute from and setting the disableTheme attribute to true. Maybe this helps you in short term. – Naveen Mar 14 '12 at 16:05
  • Thanks Naveen - I will try that out and let you know. – pipalia Mar 14 '12 at 16:09
  • 1
    Naveen it works without even setting the disableTheme option. Thank you - if you post this as an answer, I am happy to accept your answer. – pipalia Mar 15 '12 at 11:11

2 Answers2

4

I don't know whether its a bug or not, but you can emulate the behavior of disableOutputTag by removing the ID attribute from and setting the disableTheme attribute to true. Maybe this helps you in short term.

EDIT: You can refer here for more information.

Naveen
  • 6,786
  • 10
  • 37
  • 85
3

Not only does this happen when placing the xp:Text control inside a repeat but in also when you create a new XPage, add a xp:text onto it and define its value like:

<xp:text value="This is a test" disableOutputTag="true"/>

In the above example the xp:text will disappear. This is not what you would have expected. I would expect that only the value would be visible on the rendered page. But I think I can explain why this happens. Since there are no tags defined (disableoutputtag) somewhere in the rendered of this component it states that it should not generate anything. Because it can not bind its id to 'nothing' and so on.

Anyway, I could not think of a scenario where I would like to render plain text without any surrounding tags. It should at least be surrounded by a span or paragraph (<p>) tag so you can style it. And an ID would be nice so I can change the contents with a partial refresh.

Naveen
  • 6,786
  • 10
  • 37
  • 85
jjtbsomhorst
  • 1,667
  • 11
  • 28
  • 2
    There are many scenarios when you don't want the surrounding tags, when you are using it to generate your own HTML for example. Or when you have a repeat control and you wish to add based on the index variable etc etc. In classic Notes web development using forms, we can insert a field on a form and compute the value or use LS to populate the value. I normally achieve similar effect using a computed text to generate HTML in xpages, unless there are other ways to do it in xpages? – pipalia Mar 14 '12 at 12:36