-   Linux - Server (
-   -   Microhttpd Library (

dan2012 03-21-2013 09:21 AM

Microhttpd Library
I want to use microhttpd for creating an embedded server. The goal is to send a request (ex : http://localhost/API/DoAction) and the server responds by executing the action, where "DoAction" executes a c++ method that has a functionnality.
How can i do that ?

Thank you

theNbomr 03-24-2013 07:13 PM

You really always have to do that. The request from the HTTP client includes a URL that may or may not have a list of options/arguments. The callback for your HTTP server will get a copy of the URL as a pointer to a string. Your code will have to parse that string and then vector according to its makeup. The code that you choose to execute is arbitrary, and will reflect the nature of the application you are trying to create.
There are numerous examples in the library source tree to get you started.
--- rod.

All times are GMT -5. The time now is 05:58 PM.