Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
register trademark
herald10
Hi,
I need to put a string with register trademark as a default value for a text field in a DCT. In the text field when I put &174; it complains "An internal problem was encountered trying to create a requirements object for type downloads/program. " . Can anyone help me out?
Thanks in advance,
-H
Find more posts tagged with
Comments
Migrateduser
Can you try
&174;
or FormAPI?
herald10
I entered the following in the DCT. It just displays &174; instead of the register trade mark.
<default>CompanyName &174; Program</default>
Thanks
-H
Edited by herald10 on 04/21/04 12:22 PM (server time).
Migrateduser
That should be fine - when you preview that content the browser should convert it to a trademark symbol.
Migrateduser
Could you just use:
®
or &reg;
- Jason
herald10
I got it to work by entering ®
Thanks
-H
Migrateduser
That must be the Chinese trademark symbol. At least in Mozilla. I would avoid using that one.
herald10
You are right! Just now I checked it in Mozilla and the DCR doesn't load with the default value set to that chinese register trademark. Is there any other way of doing it?
Thanks
-H
Migrateduser
I usually go with FormAPI everywhere instead of using <default>.
herald10
Even the formAPI thing throws the same errors. :-(
Migrateduser
Never embed FormAPI in the DCT itself (that probably shouldn't even be allowed) - it just causes XML escaping issues and makes the code harder to read, plus if your DCT exists in multiple branches/workareas you have synchronization issues (just like you do with DCTs but there is no way to avoid that). Put the .js file in IWHOME/httpd/iw/formapi/{category}/{type}.js and reference it as:
<script language="javascript" location="webserver" src="/iw/formapi/{category}/{type}.js"/>
That way there are no encoding issues and the same piece of code is shared to all instances of the DCTs. The same approach can be used to share common routines to all DCTs (except put the file in IWHOME/httpd/iw/formapi/functions.js or whatever).
JonathonG
To pick a nit:
IMHO, js files that are specific to a data type should be stored in the same directory as the datacapture.cfg. Then, they can be referenced in the datacapture simply by:
<script language="javascript" location="template-type" src="{type}.js"/>
Only js files that are universal should be stored under IWHOME/httpd/iw
Jonathon
Independent Interwoven Contractor
Migrateduser
Why? I mean, as long as you version everything custom that gets installed to IWHOME, why would you want to copy this .js file into every workarea that contanis this DCT?
JonathonG
Well, since I'd be submitting it to STAGING along with the datacapture.cfg, I wouldn't need to "copy" it to all workareas...it would just be there when I do a Get Latest.
Basically, my reasoning is that the type-specific js files tend to be much more tied to the datacapture structure than the non-type-specific. By placing them in the same directory, this relationship is much more explicit, IMHO. Plus, you don't have to duplicate the category/datatype structure under the httpd/iw directory (or the branching structure, if you've got many branches).
But, obviously, either way will work. I just think the way I've proposed is more "self-documenting"
Jonathon
Independent Interwoven Contractor
herald10
In the javascript file how do I reference the register trademark? &174; or just paste it from some where else. Because both values don't work in my script :-(
JonathonG
In your javascript file, you should just be able to use &174;
Since this isn't part of any kind of markup file, you don't need to "escape" the &.
HTH,
Jonathon
Independent Interwoven Contractor