这是我的html
<div style = "margin-left: 10px">
<img id = "prev"src="defaultimg.jpg" alt="Default Profile Pic" width="220" height = "220">
<input style="margin-top:10px;" value = "xxxx" id = "newphoto" type="file" name = "myimg">这是我的php。
$photox = $_POST['photo'];
$target = '/images/';
$photo = $target . basename($_FILES['myimg']['name']);
move_uploaded_file($_FILES['myimg']['tmp_name'], $photo);未定义的变量"mying“会发生错误。。请帮帮忙
发布于 2015-08-13 06:04:35
您可以使用JS formdata Objects
并执行AJAX
https://stackoverflow.com/questions/31980487
复制相似问题