|
-
Jan 24th, 2001, 10:28 AM
#1
Thread Starter
Hyperactive Member
Hi All,
I have decided to try and create a simple web server in c/c++, can anyone give any good links on where to get some sample code/tutorials/or info on how to go about starting this?
Thanks
Bill
-
Jan 24th, 2001, 11:30 AM
#2
Frenzied Member
Well, I don't have any links or such (well, someone has created a simple one here (www.analogx.com))
But the first thing you have to do is...
Open a port (80) : duhhh 
If someone connects, get the command.
Check what file he wants...
Send the file...
ah **** this isn't working out... 
I think looking at www.microsoft.com and searching the web would result in some standard commands and stuff.. good luck anyway.
Jop - validweb.nl
Alcohol doesn't solve any problems, but then again, neither does milk.
-
Jan 24th, 2001, 02:07 PM
#3
Thread Starter
Hyperactive Member
Well not exactly, first you create a socket, then you set it to receive and bind it to port 80, then you wait for a connection, and when one comes in you fork another socket off to handle that, so your original one is able to continue to listen for more incoming connections. Then the forked socket must go through use the http protocol designated by rfc 1945, and use that to determine what exactly the client want, still using the rfc 1945, and then serve that back to them. Then end the forked socket.
I'll give your link a look though
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|