Hi ..
can some one tell me how to send a HTTP request from c/c++ . I want do it from solaris . Does i need any lib's ?
i know libghttp.so is required ,am i right?
please send me if u have any examples on this
I don't have time to build for you an example but, know this: usually HTTP servers comunicate in clear text so, have a look at the protocol specs. After that you can test the part you'll like to use for your application using a simple telnet connection. Once you have checked it out, the only thing you have to do in your code is to open a socket connection ( have a look at the socket library ) and comunicate with your servers by the usual read and write operation.
P.S: don't forget that the usual HTTP port is 80
Sorry i can't do more
masi
ANASI c++ isn't the best language for building net applications. Java and vissual languages invented after the internet's onset is.... This would be really easy to do with JAVA or Vissual C... They typically don't cover it in a C/C++ because there are easier ways.
Most of the examples I have seen have been in C as opposed to a true OOP design (as in C++). Most C++ code relies on C linkage and uses stuff in sys/socket.h and files like that.
For example, Addison Wesley publishes "Effective TCP/IP Programming" which is C, and the Stevens books are also C.
I'd say that a book on TCP/IP programming for C++ that uses STL containers/algorithms and does stuff like read from sockets with overloaded operators, etc., would be very cool.
I don't think there is anything standard but you might even find some open source libraries that aren't "just C".
W3C used to have an open source library called "libw" that was a few years ago don't know if it's still around. -There are only 10 types of people in the world, those who understand binary and those who don't-
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.