upload picture using web server to sd card.

Yes, it's more or less the same as reading from the SDcard and write it to a webbrowser.
In this (opposite) case, you create a loop and write bytes to the SDcard while there are bytes available.
Instead of println you use print, because you write a stream of bytes and you don't want any cr/nl inserted.
When I've time, I'll look for and post an example.