Thanks for your reply.
So I should use the function parseXML(), not loadXML().
But I met the following errors...
[Fatal Error] :1:1: Content is not allowed in prolog.