[gatein-dev] Portal url creation with ampersands

Julien Viet julien at julienviet.com
Thu Oct 28 05:02:33 EDT 2010


it's a good point,

in the navigation controller framework it is possible to specify the kind of link that will be generated by the portal.

so creating an URL would be like

url.setMimeType(MimeType.XHTML);
url.toString();

or

url.setMimeType(MimeType.PLAIN);
url.toString();

On Oct 28, 2010, at 10:57 AM, Trong Tran wrote:

> it says :
> 
> Note that replacing & with &amp; is only done when writing the URL in HTML, where "&" is a special character (along with "<" and ">"). When writing the same URL in a plain text email message or in the location bar of your browser, you would use "&" and not "&amp;". With HTML, the browser translates "&amp;" to "&" so the Web server would only see "&" and not "&amp;" in the query string of the request.
> 
> I think this is a good example of reason why we have used '&' standalone before.
> 
> Anyway, I agree that the '&amp;' would be used to generate an ULR by default and we could provide an option to be able to retrieve the another in such cases
> 
> 
> On 27 October 2010 21:23, Matt Wringe <mwringe at redhat.com> wrote:
> We are running into a bunch of problems with ajax requests when the
> portal is used to create the urls (this is especially seen when using
> wsrp as it needs to rewrite urls). The issue stems from the use of '&'
> instead of '&amp;', & alone is not allowed in xhtml/xml.
> 
> I have already created a jira (with a patch) for this issue:
> https://jira.jboss.org/browse/GTNPORTAL-1597
> 
> Is there any objection or reasons why we can't use the proper '&amp;'
> instead?
> 
> _______________________________________________
> gatein-dev mailing list
> gatein-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/gatein-dev
> 
> 
> 
> -- 
> Tran The Trong
> eXo Platform SEA
> _______________________________________________
> gatein-dev mailing list
> gatein-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/gatein-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/gatein-dev/attachments/20101028/9a461fed/attachment.html 


More information about the gatein-dev mailing list