#include #include #include "microhttpd.h" // not accessible in browser because ALL URLs start with / (or with _ in dylib) char* duplicate(const char* x) { size_t len = strlen(x); char* ret = malloc(len+1); memcpy(ret, x, len); ret[len] = '\0'; return ret; } // index, path: / char* _(struct MHD_Connection* connection) { const char* resp = "This is an index page!"; return duplicate(resp); } // home, path: /home char* _home(struct MHD_Connection* connection) { const char* resp = "" "

This is a HOME page!

" "
" "Don't click me! :0" ""; return duplicate(resp); } // hentai, path: /hidden/hentai char* _hidden_hentai(struct MHD_Connection* connection) { const char* resp = "" "

what did you expect to see...

" " " ""; return duplicate(resp); }