A version of LWIP, provided for backwards compatibility.
Dependents: AA_DemoBoard DemoBoard HelloServerDemo DemoBoard_RangeIndicator ... more
HTTPLog.h
00001 #ifndef HTTPLOG_H 00002 #define HTTPLOG_H 00003 00004 #include "HTTPServer.h" 00005 00006 class HTTPLog : public HTTPHandler { 00007 public: 00008 HTTPLog(const char *prefix) : HTTPHandler(prefix) { 00009 } 00010 00011 private: 00012 virtual HTTPHandle action(HTTPConnection *con) const { 00013 struct ip_addr ip = con->pcb()->remote_ip; 00014 printf("%hhu.%hhu.%hhu.%hhu %s %s", (ip.addr)&0xFF, (ip.addr>>8)&0xFF, (ip.addr>>16)&0xFF, (ip.addr>>24)&0xFF, (con->getType() == POST? "POST" : "GET"), con->getURL()); 00015 return HTTP_AddFields; 00016 } 00017 }; 00018 00019 #endif
Generated on Tue Jul 12 2022 16:06:06 by 1.7.2