Upload a picture from Android to PHP server

前端 未结 2 541
伪装坚强ぢ
伪装坚强ぢ 2020-12-09 14:08

I am trying to upload file to a php server from my android device. There is thread with same question but he is using a different method. My Android side code works fine and

相关标签:
2条回答
  • 2020-12-09 14:53

    It seems that the server is not responding to the client. Try uploading using an ftp connection through the Android application, if that works then check your Apache configuration on accepting connections and the writable directories. When I had a similar problem it turned out that my directory gave no write privileges.

    Is the error from Java or from Apache?

    0 讨论(0)
  • 2020-12-09 14:54

    Change your code in the following way for the correct escape sequences:

    Replace

    String lineEnd = "rn";
    

    with

    String lineEnd = "\r\n";
    
    0 讨论(0)
提交回复
热议问题