Upload Image to server with multiple parameters

后端 未结 2 1432
情书的邮戳
情书的邮戳 2020-12-18 12:59

I\'m trying to upload Image to the Server, Which I have done and works very well. But the problem I\'m facing is I want to Upload Image as well as pass some parameter with t

2条回答
  •  梦毁少年i
    2020-12-18 13:47

    Try this:

    $mobileNumber = $_POST['userNumber']; // get mobile number from post
    

    Since you are using POST method:

    conn.setRequestMethod("POST");
    

    And setting mobile number as:

    conn.setRequestProperty("userNumber", usernumber);
    

提交回复
热议问题