It's all about the answers!

Ask a question

URLs in custom work item fields of type mediumHtml

Simon Webb (4685) | asked Feb 09 '09, 12:40 p.m.
I wanted to include a custom work item field that can have a value that is a URL to an external document. I would like the value to be a clickable link in both the RTC client and the browser interface, and of course I'd like it to look right in the browser as well.

I am aware that external URL links can be created in the "links" section of a work item quite easily - and they also get formatted correctly and are clickable in both the RTC client and browser. However I wanted a custom field so that I would be able to search work items easily - I was not sure that this could be done when using the "Related artifacts" link approach. Please correct me if I am wrong though since that would solve my problem a different way.

I'm nearly there, but I can't get a regular URL to appear properly in the web-client.

This is an example of a value I set using the RTC client:


The problem is that the last part of the URL gets somehow modified in the browser to read:


which causes the query to fail.

Note the "." after the ampersand and "amp". I've tried all the different combinations of "&", "&amp" and quoting of the value in the RTC client and I always seem to get extra "." in the browser links. I am not an HTML expert but have read that the correct way to include an ampersand in a URL was to use "&". As I say, I've tried as many different ways as I can think of to get it to work and failed.

I was also interested to see that even though I set the editor presentation for the field to be "smallHtml" the RTC client didn't display the value as a formatted link - in other words it displayed the HTML source for the link - but recognized it as a link and I am able to click on it.

Any help appreciated!

7 answers

permanent link
Simon Webb (4685) | answered Feb 09 '09, 12:41 p.m.
Ok - I should have disable HTML in this post.

The example should read:

<a href='' >00635,070,724</a>


permanent link
Marcel Bihr, Jazz Work Item team (1.4k) | answered Feb 10 '09, 3:44 a.m.
I have created defect 70728: to track the issue.


Jazz Work Item team

permanent link
Simon Webb (4685) | answered Feb 10 '09, 10:43 a.m.
Much appreciated Marcel.

permanent link
Andrés Guerrero (20613218) | answered May 04 '09, 11:07 a.m.
Much appreciated Marcel.

Hi all,

I have a similar problem with mediumHtml type formating on RTC2M2.
When creating a new work item with a custom mediumhtml field I get the expected formating "before" I save the workitem:

Field content:
<a href=''>Googleee</a>

Googleee (links to

But when I save the work item ... :

Field content:
<a href=''>Googleee</a>

Preview:'>Googleee (links to <server public root URI>/projects/_A)

Is there something I should know about medumHTML type?


permanent link
Andrés Guerrero (20613218) | answered May 04 '09, 11:35 a.m.
Is interesting that when I edit the mediumHtml custom field (Changing the label from Googleee to Googleeeeee for example) and click 'Preview' it works as expected again. When I save the field is wrong again.

permanent link
SEC Servizi (97122854) | answered Oct 15 '13, 5:08 a.m.
edited Oct 15 '13, 5:10 a.m.
 We are able to add an hypertext link to a custom HTML field simply using:
final String html = "[a href=\"\"]website[/a]";
wi.setValue(attribute, html);
(*) Replace [ with <.
While the Eclipse client renders the field content in the proper manner (i.e., the word "website" as a link to ""), the web client seems do not allow the HTML injection (i.e., all the content is reported as text).
 Any advice?
Thanks in advance.

permanent link
Ralph Schoon (62.0k33643) | answered Oct 15 '13, 6:21 a.m.
I have not tried with medium HTML attributes. I used the Wiki type attribute and it seems to work there. An example using JavaScript can be found here in Lab 5 at the end.

SEC Servizi commented Oct 15 '13, 7:01 a.m.

We are still on v2.0.x and the Wiki type attribute seems not to be available ( 

Ralph Schoon commented Oct 15 '13, 7:03 a.m.

Sorry, I can't even test that easily anymore, because I got rid of my 2.x installs recently.

Your answer

Register or to post your answer.