HTTPText.cppをJSON用に変更したバージョンです。 まだ未完全
Dependents: HTTPClient_IFTTT_Maker_post_HelloWorld
Fork of HTTPClient by
Diff: data/HTTPText.cpp
- Revision:
- 20:8164b7ad6115
- Parent:
- 16:1f743885e7de
--- a/data/HTTPText.cpp Fri Mar 20 14:17:14 2015 +0000 +++ b/data/HTTPText.cpp Mon Jul 13 14:03:40 2015 +0000 @@ -55,7 +55,11 @@ /*virtual*/ int HTTPText::getDataType(char* type, size_t maxTypeLen) //Internet media type for Content-Type header { +#if 1 + strncpy(type, "application/json", maxTypeLen-1); +#else strncpy(type, "text/plain", maxTypeLen-1); +#endif type[maxTypeLen-1] = '\0'; return OK; }