Using TCP/IP
Tim Roberts
timr at probo.com
Wed Oct 1 23:19:41 EDT 2003
More information about the Python-list mailing list
Wed Oct 1 23:19:41 EDT 2003
- Previous message (by thread): Using TCP/IP
- Next message (by thread): Using TCP/IP
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
jblazi <jblazi at hotmail.com> wrote: > >On Tue, 30 Sep 2003 02:09:15 +0300, Christos "TZOTZIOY" Georgiou wrote: > >> import socket >> socket.gethostbyname(socket.gethostname()) > >Thx. But this does not seem to work correctly. When I start the program >and print the result, I get an IP-address but it is not the correct one >i.e. not the one I am currently using. Perhaps you had better define "the one I am currently using" and how you are determining it. That call will give you the IP address that your computer thinks it is using. If you have gateways or firewalls, that might be completely unrelated to your external IP address. -- - Tim Roberts, timr at probo.com Providenza & Boekelheide, Inc.
- Previous message (by thread): Using TCP/IP
- Next message (by thread): Using TCP/IP
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list