|
Re: Handle special character in uri [message #521469 is a reply to message #521443] |
Wed, 17 March 2010 15:57 |
Ed Merks Messages: 33142 Registered: July 2009 |
Senior Member |
|
|
This is a multi-part message in MIME format.
--------------040806060100080400040203
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Sebastien,
Comments below.
Sebastien Leveque wrote:
> Hello,
>
> I have created a resource that contains & in its name.
> I have created a second resource that is link to the first on.
>
> When this second resource is reloaded an error is thrown saying
>
> The entity name must immediately follow the '&' in the entity reference
>
> The uri of the first document is store as is without escaping &
> character.
>
> href="My&.myelement#/"
>
> It is a bug? if not how can I handle it.
You'll need to use this option set to FALSE when saving.
/**
* Skip escaping special characters, such as '&' char, in URIs
during XML serialization.
* The default is <code>Boolean.TRUE</code>. To enforce escaping
special characters, set this
* option to <code>Boolean.FALSE</code>.
*/
String OPTION_SKIP_ESCAPE_URI = "SKIP_ESCAPE_URI";
>
> Thanks
--------------040806060100080400040203
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Sebastien,<br>
<br>
Comments below.<br>
<br>
<br>
Sebastien Leveque wrote:
<blockquote cite="mid:hnqtec$bqg$1@build.eclipse.org" type="cite">Hello,
<br>
<br>
I have created a resource that contains & in its name.
<br>
I have created a second resource that is link to the first on.
<br>
<br>
When this second resource is reloaded an error is thrown saying
<br>
<br>
The entity name must immediately follow the '&' in the entity
reference
<br>
<br>
The uri of the first document is store as is without escaping &
character.
<br>
<br>
href="My&.myelement#/"
<br>
<br>
It is a bug? if not how can I handle it.
<br>
</blockquote>
You'll need to use this option set to FALSE when saving.<br>
<blockquote><small> /**<br>
* Skip escaping special characters, such as '&' char, in URIs
during XML serialization.<br>
* The default is <code>Boolean.TRUE</code>. To enforce
escaping special characters, set this <br>
* option to <code>Boolean.FALSE</code>.<br>
*/<br>
String OPTION_SKIP_ESCAPE_URI = "SKIP_ESCAPE_URI";</small><br>
</blockquote>
<blockquote cite="mid:hnqtec$bqg$1@build.eclipse.org" type="cite"><br>
Thanks
<br>
</blockquote>
</body>
</html>
--------------040806060100080400040203--
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.03003 seconds