Please support our Java advertiser: Lunarpages Java Web Hosting
Views: 1035 | Replies: 2
![]() |
•
•
Join Date: Jul 2005
Posts: 56
Reputation:
Rep Power: 4
Solved Threads: 0
Web servers are text based so they are rather simple.
For the basic version just...
Create it like any other client / server program. HTTP is a connection oriented protocol (been a while) so you will want to make sure to use that method to create your socket. After that is done all you need to know is what exactly the client will send you as a request (should be able to be found using google and the HTTP spec) and then write the code to read in a HTML file and send it over the network, which in java is pretty much the same as writing it to the hard drive...
For the basic version just...
Create it like any other client / server program. HTTP is a connection oriented protocol (been a while) so you will want to make sure to use that method to create your socket. After that is done all you need to know is what exactly the client will send you as a request (should be able to be found using google and the HTTP spec) and then write the code to read in a HTML file and send it over the network, which in java is pretty much the same as writing it to the hard drive...
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)






Linear Mode