<?php
/**
*Recieve p_w_picpath data
**/
error_reporting(E_ALL);
function get_contents()
{
$xmlstr = file_get_contents("php://input");
$filename = time() . '.png';
if (file_put_contents($filename, $xmlstr)) {//將數據存儲進圖片格式中
echo 'success';
} else {
echo 'failed';
}
}
//get_contents();
var_dump(file_get_contents('1565341389.png')); //讀取圖片,獲取圖片中的數據
die();

