OLD
OLD
Diff: GSwifi.h
- Revision:
- 15:5febfc399099
- Parent:
- 12:63e714550791
- Child:
- 16:aea56cce3bf5
--- a/GSwifi.h Fri Oct 05 16:42:50 2012 +0000 +++ b/GSwifi.h Tue Oct 09 16:05:40 2012 +0000 @@ -302,12 +302,23 @@ * @return CID, -1:failure * If you use ssl, please set system time. */ + int httpGet (Host &host, char *uri, int ssl, char *user, char *pwd, onGsReceiveFunc ponGsReceive = NULL); int httpGet (Host &host, char *uri, int ssl = 0, onGsReceiveFunc ponGsReceive = NULL); /** + * http request + * @return CID, -1:failure + * If you use ssl, please set system time. + */ + int httpPost (Host &host, char *uri, char *body, int ssl, char *user, char *pwd, onGsReceiveFunc ponGsReceive = NULL); + int httpPost (Host &host, char *uri, char *body, int ssl = 0, onGsReceiveFunc ponGsReceive = NULL); + /** * certificate */ int certAdd (char *name, char *cert, int len); + int base64encode (const char *input, int length, char *output, int len); + int urlencode (char *str, char *buf, int len); + void test (); int getc(); void putc(char c);