In a HTML page I have an upload form this like:
<form action="upload" enctype="multipart/form-data" method="POST">
<input name="convertfile" type="file">
<input type="submit" value="Upload">
</form>
Is there any way in HTML to specify that the filedata (or the HTTP form content of the POST), should be sent with GZIP content-encoding?
I would like the client to compress the selected file before uploading. Is this something you could only achieve in Javascript?
This is done automatically if the client browser and the server support compression and can agree on a common compression algorithm (which is almost always the case nowadays).
From "Compression in HTTP" by MDN Web Docs, 26 Mar. 2024: