Home
Web CMS (TeamSite)
special characters in job description
System
Since things like ampersand are illegal in XML, what are people doing to check if users are entering such characters in job descriptions, comments, etc. that end up in workflow XML?
Find more posts tagged with
Comments
Johnny
I always thought TeamSite converts them into proper XML syntax for internal storage eg DCR's.
I know it does this with DCT entry forms.
Its not the case for WF???
John Cuiuli
Consultant
Sydney, Australia
Adam Stoller
Seems to work just fine in a simple test I did. I used & in the job description and <angle> brackets in the file comments and it had no problem displaying them literally within the To Do List.
--fish
(Interwoven Senior Technical Consultant)
Migrateduser
What workflow are you using? Are you sure it's not doing something to the job description? If I create a job with "this is a job description with & and > and <" I get a JavaScript popup that says "not well-formed at line 9". Line nine looks like the workflow instantiator did nothing with my description.
<description>this is a job description with & and > and < </description>
Here's the snipet of code from the .wft:
...
my ${iw_desc} = __VALUE__( 'iw_desc' );
...
<description>__INSERT__( ${iw_desc} );</description>
This is on 5.5.2SP2 but I remember having the same issue in 4.5.1 and doing custom substitutions on the description in the .wft.
Adam Stoller
The wft I was using has:
=============
TAG_info(
# The string to be used as the job's description.
job_description =>
[ label => '',
html => 'Job Description:<br>'
. '<textarea rows=3 cols=50></textarea><br> ',
is_required => 'true',
error_msg => 'Please enter a description',
],
);
===================
and then:
===================
<workflow ... description="__TAG__('job_description');">
===================
This is with 5.5.2 SP2 on W2K - using IE 5.5 as my browser.
--fish
(Interwoven Senior Technical Consultant)
Migrateduser
Must be code in the __TAG__ (subroutine?), which I can't use in this case.
Adam Stoller
Try something like:
my $iw_desc = TeamSite::CGI_lite::escape_html_data(__VALUE__(iw_desc));
description="__INSERT__($iw_desc);"
--fish
(Interwoven Senior Technical Consultant)
JamJamT
I get the same error when filling in the job description using special French characters: ç é etc.
I tried the CGI_lite::escape_html_data suggestion - same error.
Isn't TS 5.5.2 suppose to better handle these types of special characters?