1
0
mirror of synced 2025-07-27 23:41:48 +03:00
This commit is contained in:
yhirose
2020-05-26 18:20:56 -04:00
parent b91540514d
commit 3eaa769a2d
3 changed files with 59 additions and 20 deletions

View File

@ -559,13 +559,21 @@ The server applies gzip compression to the following MIME type contents:
* application/xml
* application/xhtml+xml
### Compress content on client
### Compress request body on client
```c++
cli.set_compress(true);
res = cli.Post("/resource/foo", "...", "text/plain");
```
### Compress response body on client
```c++
cli.set_decompress(false);
res = cli.Get("/resource/foo", {{"Accept-Encoding", "gzip, deflate"}});
res->body; // Compressed data
```
Split httplib.h into .h and .cc
-------------------------------