IBM Rational Change: Issues with single and double quotes in RTF fields

Technote (troubleshooting)


Change changes the way single and double-quotes are interpreted in RTF fields (such as "WSLET") at the time Javascript is produced. This can cause issues in your customized code when your browser interprets the produced code.


Try to use a variable as below with an attribute MY_ATTRIBUTE of type CCM_EXTENDED_TEXT:

var currentSituation  = "<!-- WSLET CODE=PTText --><!-- PARAM NAME=CCM_STRING VALUE='MY_ATTRIBUTE' --><!-- /WSLET -->";

Then, give it a value as below (please note the presence of two "single quote" characters in the sentence):
It's an example of how single quotes' interpretation causes trouble.

The code produced can eventually cause issues on the final page when it's rendered in a browser (errors on the page, incorrect display, etcetera.)


This has been identified as a product defect under APAR PM68408

The root cause is a combination of both :

    • a change in the product's behavior...

    • a confusion in the attributes types in your custom code.

  • In Change, the example above would eventually produce a code similar to this, in HTML:

       var currentSituation = " &lt;div&gt; &lt;div style=&quot;mso-line-spacing:&amp;quot;108 0.....

  • In Change, it will produce a code like this :

        var currentSituation = "<div> <div style=""><span style="font-family:...

Please observe how &quot; is now directly replaced by quote characters. This is a new behavior in Rational Change. Because of this, the single quotes or double-quotes present in the code can now "confuse" the browser when there is an odd number of them.

HOWEVER, this bad translation of the quote characters happens more specifically when there is a confusion in your custom code between:
- the data type used for the attribute on the one hand,
- the data type used in the instruction to get the value of the attribute, on the other hand.

For example :
In the instruction below, we use the " CCM_STRING" type.

  var currentSituation = "<!-- WSLET CODE=PTText --><!-- PARAM NAME=CCM_STRING VALUE='MY_ATTRIBUTE' --><!-- /WSLET -->";

but in the attribute MY_ATTRIBUTE is of type " CCM_EXTENDED_TEXT".

See the "Resolving the problem" section.

Diagnosing the problem

Simply use an instruction similar to the one below, and observe the code produced in the final HTML page (compare it with the examples above, from the "Cause" section of this Technote)

    'var currentSituation = ""; '

Resolving the problem

Upgrade to the release of Change that includes APAR PM68408.

In the mean time, make sure you're consistent in your attributes types.

In the example described in the "Cause" section of this Technote, you must replace "CCM_STRING" with "CCM_EXTENDED_TEXT", because the attribute MY_ATTRIBUTE is indeed of type CCM_EXTENDED_TEXT :

var currentSituation = "<!-- WSLET CODE=PTText --><!-- PARAM NAME=

Rate this page:

(0 users)Average rating

Add comments

Document information

More support for:

Rational Change
General Information

Software version:,,

Operating system(s):

AIX, Linux, Solaris, Windows

Reference #:


Modified date:


Translate my page

Machine Translation

Content navigation