This is version . It is not the current version, and thus it cannot be edited.
[Back to current version]   [Restore this version]
TitleFirefox does not like escaped / char in URL
Date26-Jan-2005 05:08:13 EET
Version2.1.86 alpha
Bug criticalityMediumBug
Browser versionFirefox
Bug statusNewBug
PageProvider used
Servlet ContainerTomcat 4.1.30
Operating SystemSolaris
Java version1.4.2_05

When an image is inlined by JSPWiki it escapes the URL including the / char. This works in IE but causes Firefox to obtain a file from some cache somewhere, the file equates to the first version of any attached image.

In my case this is bad news since users are developing code based on the diagrams and firefox users will see old versions !!

The following change to com.ecyrd.jspwiki.TextUtil fixed the problem

     * method in JDK < 1.4 is buggy.  This duplicates
     *  its functionality.
    protected static String urlEncode( byte[] rs )
        StringBuffer result = new StringBuffer();

        // Does the URLEncoding.  We could use the one, but
        // it does not eat byte[]s.

        for( int i = 0; i < rs.length; i++ )
            char c = (char) rs[i];

            switch( c )
              case '_':
              case '.':
              case '*':
              case '-':
                result.append( c );
                //we dont want / escaped, it breaks urls in firefox
              case '/':
                  result.append( c );

              case ' ':
                result.append( '+' );


The fix is already in the current alpha release (2.1.144). Perhaps this would be able to explain BugStaleAttachments?

-- JanneJalkanen

Add new attachment

Only authorized users are allowed to upload new attachments.
« This particular version was published on 27-Jan-2005 14:55 by Administrator.