[EMAIL PROTECTED] wrote:
> Where can I get the Host server's IP address?
>
> request.META['SERVER_NAME'] simply returns localhost instead of
> whatever my ip address is
>
>
Try
import socket
socket.gethostbyname(request.META['SERVER_NAME'])
regards
Steve
On Fri, Nov 21, 2008 at 5:14 PM, [EMAIL PROTECTED] <[EMAIL PROTECTED]>wrote:
>
> Where can I get the Host server's IP address?
>
> request.META['SERVER_NAME'] simply returns localhost instead of
> whatever my ip address is
>
Your machine likely has more than one IP address: one for each network
Where can I get the Host server's IP address?
request.META['SERVER_NAME'] simply returns localhost instead of
whatever my ip address is
Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
3 matches
Mail list logo