Created
January 16, 2018 05:23
-
-
Save blue0513/7f772c0ad1e78903a3839e78bffbba0a to your computer and use it in GitHub Desktop.
upload data from unity to server
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(isset($_FILES['theFile'])) { | |
$uploaddir = "YOUR DATA PATH"; | |
$uploadfile = $uploaddir . basename($_FILES['theFile']['name']); | |
if(move_uploaded_file($_FILES['theFile']['tmp_name'], $uploadfile)){; | |
echo "success"; | |
} | |
} else { | |
echo "fail"; | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment