Sign in to follow this  
levjs

[web] App to CGI to APP

Recommended Posts

Hi, How would I have an application, run on a customer's computer, pass a variable to and run a CGI script on my webserver. Then, depending on what the variable was, how would I send the application on my customer's back a TRUE or FALSE message? Can this be done? The app on the customer's computer would be a C++ app run on windows. Thanks Levi

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
You'd use the POST or GET method, as described in the HTTP RFC [1]. The CGI will write the result to stdout and the webserver will send it back "as-is" to the client. You'll have to parse the returned result and convert it to a boolean value.

Alternatively, you could use a web service: that's what they were designed for. If you must use a web server, then it's an option.


Hope this helps.

[1]. HTTP 1.0: http://www.w3.org/Protocols/rfc1945/rfc1945, HTTP 1.1: http://www.w3.org/Protocols/rfc2616/rfc2616.html

Share this post


Link to post
Share on other sites
Ooh, simple enough. So the only reason it sends it to IE or whatever browswer is running when I call the CGI script on my web browser is because the web browser called it. : ) I like that!

So how would I call a cgi script from a C/C++ program? Would something like CreateProssecc work?
Thanks
Levi

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this