需要在头部加上header("Content-Type: p_w_picpath/png"); //声明其后内容是png图片数据(这个很重要)这句话 转载于:https://blog.51cto.com/mazongfei/1270850