| Title | Wiki Translate Tag Should Trim Leading Spaces Of First Sentence |
| Date | 23-Mar-2005 20:10:29 EET |
| Version | 2.1.144 |
| Submitter | MikeTaylor |
| Bug criticality | JSPWiki:CosmeticBug![]() |
| Browser version | Not Relevant |
| Bug status | ClosedBug |
| PageProvider used | Not Relevant |
| Servlet Container | Not Relevant |
| Operating System | Not Relevant |
| URL | Not Relevant |
| Java version | Not Relevant |
IF someone changes the template file PreviewContent.jsp, and reformats the <wiki:Translate> tags, translation will fail for the first line if the production rule it expects to have applied reuqires that the character start at the beginning of a line.
Example:
<wiki:Translate>
<%=pageContext.getAttribute("usertext",PageContext.REQUEST_SCOPE)%>
</wiki:Translate>
IF the page looks like:
!!! Big heading !! Little heading
Then translator will actually see:
!!! Big heading
!! Little heading
I would argue that translate should trim whitespace and blank lines until the first non-whitespace character is encountered. I doubt that anyone will actually lose any whitespace they wanted to keep in this case.
Cheers,
Mike
Fixed in 2.2.19.
