|Title|ShortViewURLConstructor and ShortURLConstructor problems
|Date|20-Jul-2005 00:24:11 EEST
|Version|2.2.28
|Submitter|OlafKock
|[Bug criticality]|[JSPWiki:LightBug]
|Browser version|Firefox
|[Bug status]|ClosedBug
|[PageProvider] used|VersioningFileProvider
|Servlet Container|tomcat 5
|Operating System|Linux
|URL|
|Java version|1.4.2

Either I'm not getting it right at this time of the day or something is wrong here. At least the documentation delivered with 2.2.28 is questionable on the topic of [ShortViewURLConstructor] and [ShortURLConstructor]:

The documentation says you ''may'' set {{jspwiki.shortURLConstructor.prefix}}, but in my opinion you ''must'' set it - even to an empty value, because otherwise it adds 'null' to the path of generated urls.

I'd like some confirmation from others before I'd change this on [http://doc.jspwiki.org/2.2/wiki/ShortViewURLConstructor] - comments? Are there other options that I've missed?

-- OlafKock

You're right. Fixed in 2.2.29.

-- JanneJalkanen

I am confused: the comment above was written in July. where can I get 2.2.29? 2.2.28 still is the last version that can be downloaded as of end of August.

-- Gregor Hagedorn - 2005-08-30

It's fixed in a version that is named (at least) 2.2.29 which will be available as soon as it is released - unfortunately that's ''not yet'' ;-)

I believe that Janne doesn't want to release too often if there are no FatalBugs or CriticalBugs (probably BadBugs) fixed. This is only a LightBug

-- OlafKock 2005-09-02


----

I have JSPWiki v2.4.85-cvs running with the DefaultURLConstructor and container-managed security, context root is wiki.

When I try the ShortViewURLConstructor and access
{{{http://linux:8080/wiki}}} it redirects to 
{{{http://linux:8080/wiki/Login.jsp?redirect=Main}}}

When I log in I am at {{{http://linux:8080/wiki/wiki/Main }}}
and the CSS is not found.

The HTML source shows @import url(templates/mine/mine.css) which definitely is not right. 

Same for ShortURLConstructor.

So, it seems there is something broken with ShortViewURLConstructor and ShortURLConstructor together with container-managed security.


--Jürgen Weber, 15-Dec-2006

----

Entirely possible.  I'll make a note of this - it looks like we're doing a redirect to a relative URL instead of absolute.

-- JanneJalkanen

----
\\
The JSPWiki gives error 404 whenever I set ShortViewURLConstructor prefix as "help". The tips in [Glassfish Wiki  »  ShortURLConstructor|http://wiki.glassfish.java.net/Wiki.jsp?page=ShortURLConstructor] solved my problem by suggesting to add the following lines in web.xml:

{{{
   <servlet>
       <servlet-name>WikiServlet</servlet-name>
       <servlet-class>com.ecyrd.jspwiki.WikiServlet</servlet-class>       
   </servlet>

   <servlet-mapping>
       <servlet-name>WikiServlet</servlet-name>
       <url-pattern>/help/*</url-pattern>
   </servlet-mapping>

}}}

Now I have a working shortViewURLConstructor!

-- knyuen