mirror of
https://github.com/lammertb/libhttp.git
synced 2025-07-29 21:01:13 +03:00
Updated comments
This commit is contained in:
@ -3,7 +3,7 @@
|
|||||||
* License http://opensource.org/licenses/mit-license.php MIT License
|
* License http://opensource.org/licenses/mit-license.php MIT License
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Simple example program on how to use Embedded C++ interface.
|
// Simple example program on how to use Embedded C interface.
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#include <Windows.h>
|
#include <Windows.h>
|
||||||
#else
|
#else
|
||||||
@ -68,7 +68,7 @@ int main(int argc, char *argv[]) {
|
|||||||
mg_set_request_handler(ctx,EXAMPLE_URI, ExampleHandler,0);
|
mg_set_request_handler(ctx,EXAMPLE_URI, ExampleHandler,0);
|
||||||
mg_set_request_handler(ctx,EXIT_URI, ExitHandler,0);
|
mg_set_request_handler(ctx,EXIT_URI, ExitHandler,0);
|
||||||
mg_set_request_handler(ctx,"/a", AHandler,0);
|
mg_set_request_handler(ctx,"/a", AHandler,0);
|
||||||
mg_set_request_handler(ctx,"/a/b", ABHandler,0); // going out of order with this to see if it will work.
|
mg_set_request_handler(ctx,"/a/b", ABHandler,0);
|
||||||
|
|
||||||
printf("Browse files at http://localhost:%s/\n", PORT);
|
printf("Browse files at http://localhost:%s/\n", PORT);
|
||||||
printf("Run example at http://localhost:%s%s\n", PORT, EXAMPLE_URI);
|
printf("Run example at http://localhost:%s%s\n", PORT, EXAMPLE_URI);
|
||||||
|
@ -72,7 +72,7 @@ int main(int argc, char *argv[]) {
|
|||||||
server.addHandler(EXAMPLE_URI, new ExampleHandler());
|
server.addHandler(EXAMPLE_URI, new ExampleHandler());
|
||||||
server.addHandler(EXIT_URI, new ExitHandler());
|
server.addHandler(EXIT_URI, new ExitHandler());
|
||||||
server.addHandler("/a", new AHandler());
|
server.addHandler("/a", new AHandler());
|
||||||
server.addHandler("/a/b", new ABHandler()); // going out of order with this to see if it will work.
|
server.addHandler("/a/b", new ABHandler());
|
||||||
|
|
||||||
printf("Browse files at http://localhost:%s/\n", PORT);
|
printf("Browse files at http://localhost:%s/\n", PORT);
|
||||||
printf("Run example at http://localhost:%s%s\n", PORT, EXAMPLE_URI);
|
printf("Run example at http://localhost:%s%s\n", PORT, EXAMPLE_URI);
|
||||||
|
Reference in New Issue
Block a user