You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Marcus <mv...@gmail.com> on 2007/05/26 04:18:34 UTC

T5 HttpServletRequest

Hi,

How can i get HttpServletRequest.getRemoteAddr() in T5?

Marcus

Re: T5 HttpServletRequest

Posted by Marcus <mv...@gmail.com>.
Yes!

Thank you Petros and Howard!

Marcus

Re: T5 HttpServletRequest

Posted by Howard Lewis Ship <hl...@gmail.com>.
You need to update your Maven pom.xml file to include the Servlet API on the
classpath.

      <dependency>
        <groupId>javax.servlet</groupId>
        <artifactId>servlet-api</artifactId>
        <version>2.4</version>
        <scope>provided</scope>
      </dependency>


On 5/26/07, Marcus <mv...@gmail.com> wrote:
>
> Hi Petros,
>
> using this code i have that compilation error in eclipse:
>
> The type javax.servlet.http.HttpServletRequest cannot be resolved. It is
> indirectly
> referenced from required .class files
>
> thanks,
>
> Marcus
>



-- 
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com

Re: T5 HttpServletRequest

Posted by Marcus <mv...@gmail.com>.
Hi Petros,

using this code i have that compilation error in eclipse:

The type javax.servlet.http.HttpServletRequest cannot be resolved. It is
indirectly
 referenced from required .class files

thanks,

Marcus

Re: T5 HttpServletRequest

Posted by petros <pe...@cypoz.com>.
You can try the following. I tried it on T5.0.4

@Inject
@Service("RequestGlobals")
private RequestGlobals requestGlobals;

requestGlobals.getHTTPServletRequest().getRemoteAddr()

Petros


Marcus-11 wrote:
> 
> Hi,
> 
> How can i get HttpServletRequest.getRemoteAddr() in T5?
> 
> Marcus
> 
> 

-- 
View this message in context: http://www.nabble.com/T5-HttpServletRequest-tf3819163.html#a10815021
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org