TitleSuspected minor bugs involving ampersand
Date29-Aug-2005 14:58:30 EEST
Bug criticalityLightBug
Browser version
Bug statusClosedBug
PageProvider usedJDBC
Servlet ContainerTomcat 55
Operating System
Java version

I encountered the follwing in PageModified.jsp:

    usertext = TextUtil.replaceString( usertext, "<", "&lt;" );\\
    usertext = TextUtil.replaceString( usertext, ">", "&gt;" );\\
    usertext = TextUtil.replaceString( usertext, "\n", "<BR />" );\\
The purpose seems to be to make something ready to be displayed in html. However, in xthml at least the ampersand would have to be escaped as well. On the other side, the status of character entities (such as Auml;   or nbsp;) in JSP Wiki pages seems to be undefined. Logically they should be onyl supported if html is turned on, and if html is enabled, all & should be illegal and char. entities untranslated.

Also note: <BR /> needs to be <br /> for xhtml.

Related: In TranslateReader.java I found commented out:\\
  /*  case '&': s = "&amp;"; break; */\\
which I believe should be:\\
  case '&': s = m_allowHTML ? "&" : "&amp;"; break;\\


Should be mostly fixed in 2.3.31.

-- JanneJalkanen

Add new attachment

Only authorized users are allowed to upload new attachments.
« This page (revision-4) was last changed on 16-Oct-2005 14:29 by Administrator