Sunday, September 12, 2010

Re: getHostPageBaseURL inconsistent across dev/deployed modes

On Sep 11, 12:13 am, Mark <mwchristian...@gmail.com> wrote:
> It seems using GWT.getHostPageBaseURL() gives me inconsistent results
> depending on which mode I am in.
>
> I expect to see something such as:  http://localhost:8080/
> I get that result in hosted mode.
>
> However, when I deploy to tomcat, the same function returns:http://localhsot:8080/<Module>
>
> Does anyone know why this is happening?  I really don't want to hack
> the API results.

getHostPageBaseURL() returns the URL of your "HTML host page" (the one
containing the <script> element that loads your application's
*.nocache.js), minus the page "filename" itself, so you can easily
build links relative to your host page.

In DevMode, your app is deployed as if it were a ROOT.war.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.

No comments:

Post a Comment