So, you're using no particular web app name right (so the root that is)?

I get things like http://localhost:8080/compref?bookmarkablePage=wicket.examples.compref.PanelPage, http://localhost:8080/guestbook?path=0 (home page), etc.

Which version of Wicket are you using?

I think it is right when there is /no/ trailing slash. That way you can allways denote your webapp resources relatively from the root (e.g. subdir/subsubdir/pic.gif). No need for doing stuff like ../../pic.gif.

Eelco


Philip A. Chapman wrote:

Everyone,

This email will probably be a little difficult to read because I have
tried to put sample code in here, but please hang in there and see if
you can help me.

I am linking in a CSS page using a relative path.  On most pages it's
not working because of how paths are being created.  In a
Form.onSubmit(), the following code:

                                        
setResponsePage(getApplicationSettings().getDefaultPageFactory()
        .newPage(getApplicationPages().getHomePage(),
                (PageParameters) null));


produces a url like :


http://server/app/?bookmarkablePage=package.web.Home


This is correct.  Everywhere else, I use static inner class
implementations of PageLink and BookmarkablePageLink:


public static PageLink link(final String name, final Integer id)
{
 return new PageLink(name, new IPageLink()
   {
     public Page getPage()
     {
       if (id == null) {
         return new EditReport(new Report());
       } else {
         return new             EditReport(Report.lookup(id));
       }
     }

     public Class getPageIdentity()
     {
       return EditReport.class;
     }
 });
}


produces a URL like


http://server/app?bookmarkablePage=package.web.ReportsListing


The lack of a slash after the servlet application name "app" makes it so
that the browser cannot find the css style page.

Thanks,



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to