Trouble retrieving client IP address in WO 5.2
Trouble retrieving client IP address in WO 5.2
- Subject: Trouble retrieving client IP address in WO 5.2
- From: mjew <email@hidden>
- Date: Tue, 14 Jan 2003 14:57:49 -0800
I am attempting to retrieve the client IP address in a WO 5.2 app.
I found more than one document that said I could retrieve the IP address
using the following method:
clientIP = context().request().headerForKey("x-webobjects-remote-addr");
I do know that call is NOT supposed to return anything in direct (testing)
mode, but that it IS supposed to return the IP address of the client when
running on the application server.
This call seems to return nothing for me in both testing and on the
application server. Has the method of retrieving the client IP address
changed in WO 5.2, or am I doing something wrong?
I have been able to use
aUserAgent = context().request(). headerForKey("user-agent");
successfully, so I know that in general the technique is working.
I am imagining that I might just be using the wrong header key?
- Matthew
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.