xml和http都是文本文件,直接拼装一个xml返回即可。header("Content-type:text/xml;charset=UTF-8");
echo "<?xml version="1.0" encoding="UTF-8"?><root>Zswang 路过</root>";