function makeWord($content){
$filename = date('YmdHis');
extract($content);
foreach ($pic as $key => $value) {
if($value){
$key = '123<img src="https://172.16.59.56:28443/app/helpers/tcpdf/examples/images/{$key}.png">';
}
header('pragma:public');
header('Content-type:application/vnd.ms-word;charset=utf-8;name="'.$filename.'".doc');
header("Content-Disposition:attachment;filename=$filename.doc");
$html = '<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40"><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>';
echo $html.$key.'</html>';
}
}
是我图片地址不对么,但是我的链接地址是可以打开的,我测试了。word里面只有123,图片显示错误