Simple Server - 1.1
Tiny threaded Server and Database Application
Teb Toddy
(steelo)
Changes
Links
Releases
Simple Server 1.1 — 25 Jul, 2011
Simple Server 1.0 — 22 Jun, 2011
Pygame.org account Comments
-
Moe Win 2011-06-22 19:14
Hello fri: Firstly , I 'm newbie in python .I'm learning client server application . Can u explain soc.connect((HostIP, Port))
this one . how to setup host ip and port??
Thanks -
teb 2011-06-22 19:32
Hey Moe
HostIP and Port are Variable which i define in top of the program. HostIP is now "" (empty). the socket module will assume a localhost then, i think you could also write "localhost". if you want other people to connect to your server, put the IP to the "" where it belong in variable definitions at top. Hope i could help, here is a link to a newer version, i put the IP 107.107.107.107 for you in http://pastebin.com/Km9cg78S the port you can set to pretty much anything thats open on your computer and the client. -
teb 2011-06-24 10:42
server: http://pastebin.com/YnaDdRZw
client: http://pastebin.com/gHuQ0Z12
you may create any kind of jobs now to exchange data, this one is a basic chat.
guess thats it for the moment, client calling for a game =) -
Blakeandrewwood 2011-09-18 07:52
Hi teb, i'm trying to get this to work but i keep getting and error:
Traceback (most recent call last):
File "/Users/name/Desktop/untitled folder/client.py", line 32, in <module>
soc.connect((HostIP, Port))
File "<string>", line 1, in connect
error: [Errno 61] Connection refusedi've tried putting localhost in for the IP and i've tried setting it to my IP. Do you knopw what could possibly be wrong?