Feb 4, 2014 at 4:21pm UTC
Hi to whole,
I have a question about this code found in Stackoverflow website =>
I have seen what the author this topic answer what had resolved problem add to code base64 codification before send data. I already make a "reproduction" based in he speak like this:
"Content-Transfer-Encoding: base64; boundary=%s",boundary,content);
but not had success.
All will be welcome! Thank.
PS: Sorry my English :D
Last edited on
Feb 4, 2014 at 4:22pm UTC
Feb 4, 2014 at 4:26pm UTC
Content doesn't have a format specifier and won't be written.
"Content-Transfer-Encoding: base64; boundary=%s",boundary, content);
Did you read the answer to the post? The answer was don't use sprintf to try to format binary data, but that's exactly what you're trying to do.
Feb 4, 2014 at 5:08pm UTC
base64 is NOT binary data, so it should be safe to use sprintf in this case. However this is not the proper way to upload a file to a webserver (the size will increase and you should already have data encoded in base64)
Feb 4, 2014 at 5:26pm UTC
Thanks for reply,
You is correct KBW, I only not understood how he make work this using base64 encode :D .