Ok Jeffrey, it's all clear now! I thought there was a way to set the
base url, but there is not, as you've said, I've to "play" with the
GWT.isProdMode and get the base url.

Thank you very much, you've been very, very helpful.

Greetings!!

P.S.: y buena suerte tambiƩn para ti ;)

On 8 nov, 02:57, Jeff Chimene <jchim...@gmail.com> wrote:
> On 11/07/2011 06:33 PM,Sabbiawrote:
>
> > Gracias Jeffrey ;) So, as I've understood, the best thing is to check
> > if application is executing in production mode, and if not, use
> > GWT.getServletContext().getRealPath("my_app"), right?
>
> Well, the exact mechanism that's inside the if(production) {} is up to
> you. I don't use Spring, so you're on your own there. It looks like
> you're on the right track, though: do one thing in development, do
> something else in production. The key is to decide based on
> GWT.isProdMode().
>
> Bueno Suerte,
> jec
>
>
>
>
>
>
>
>
>
> > Thank you very much!
>
> > Cheers!!
>
> > On 7 nov, 14:59, Jeffrey Chimene <jchim...@gmail.com> wrote:
> >> On 11/6/2011 11:23 PM,Sabbiawrote:
>
> >>> Hi everyone!
>
> >>> I've developed a GWT-SmartGWT application using Eclipse. In this
> >>> application, a Java class from the server side must read some txt
> >>> files in a directory called "Transcriptions". Working with Eclipse, I
> >>> had no problem at all to access to this directory. I had located it
> >>> under the WAR directory, so every time I needed to read a file I had
> >>> only to write "File f = new File('Transcriptions');".
>
> >>> But when I've deployed it into Tomcat, I can't access to my directory
> >>> in this way anymore, because the default path of Tomcat is "webapps".
> >>> So, I need to access to the transcriptions directory using a relative
> >>> path. And here is my problem. I don't know where to locate this
> >>> directory, and I don't know how to access it.
>
> >>> I had thought of using the GWT.getModuleName() method, but because of
> >>> I have to use it in the server side, I can't use any of the methods of
> >>> GWT class.
>
> >>> I've been trying to solve it in the last week, but I've not been able
> >>> to do it.
>
> >>> Can anyone help me, please? Thank you very, very much in advance
>
> >>> Greetings!
>
> >> I'd use a two string Resources, one for production and one for test.
> >> Check the environment using 
> >> GWT.isProdMode()http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/googl...()
>
> >> Bueno Suerte,
> >> jec

-- 
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+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to