What i want to do:
I need to do a POST to a PHP Service using HttpWebRequest, and upload an image file as a Base64(can't change this) string along with other parameters and write the Base64 data in a database.
What i do:
What doesn't work
Thanks in advance!
The problem was actually in the Base64 string where in C# there was some '+' symbols and on the PHP side the '+' were removed for some reasons.
I just added the following line:
$data = str_replace(' ', '+', $data);
Now all work fine.
Thanks!
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.