Is the nagging boss still there? XML parsing error, 5555

Source: Internet
Author: User
Is the nagging boss still there? XML parsing error for help, 5555 & lt ;? Xml & nbsp; version = & quot; 1.0 & quot; & nbsp; encoding = & quot; gb18030 & quot; & nbsp ;? & Gt; & nbsp; is my boss still there? XML parsing error for help, 5555

Too many requests.

How can we ensure that the characters in the tag conform to XML? What should I do?
It is really difficult to ensure the accuracy of the XML document, so that it can make php xml parsing function parsing
Is there any XML parser such as regular expressions.
I only want to parse this document. how can I remove/replace these characters? What are these characters?

Thank you.

------ Solution --------------------
This problem should not exist with UTF-8

1. change

Too many requests.

2. Save the xml file in UTF-8 format as a record

3. the php file itself is also saved as UTF-8 in Notepad.

4. add the php file header
Header ('content-type: text/html; charset = utf-8 ');


Welcome to the QQ group for PHP enthusiasts: 30169840
------ Solution --------------------
Hehe, UTF-8 encoding format should be no problem.
However, it is estimated that the landlord does not like this format of UTF-8.

------ Solution --------------------
Let me help you. Looking forward to the answer.
------ Solution --------------------
咔咓吚.
------ Solution --------------------
I do not need to use UTF-8 encoding. I only write php programs. the code is gb2312. at the beginning, I also reported the encoding error. later I changed it to UTF-8, the result is changed to gb2312! Some people say that it seems that we only need to ensure the encoding of several pages is consistent, and the code remains to be verified!
------ Solution --------------------
Jom_ch answered the question.
Only CSDN automatically converts "<" to "<.


咔咓吚 </test> .
------ Solution --------------------
$ Str =" Too many requests. ";
//.....
$ Str = preg_replace ("/[\ x00-\ x08 \ x0b-\ x0c \ x0e-\ x1f]/", '', $ str );
$ Str = htmlspecialchars ($ str );
------ Solution --------------------
The above error is reported.
Htmlspecialchars should be transcoded before being placed In
------ Solution --------------------
Haha, I usually do this:

Function SBC_DBC ($ Str)
{
// ---- Convert all corners into halfwidth ----
$ Queue = Array (
'0' => '0', '1' => '1', '2' => '2', '3' => '3 ', '4' => '4 ',
'5' => '5', '6' => '6', '7' => '7', '8' => '8 ', '9' => '9 ',
'A' => 'A', 'B' => 'B', 'c' => 'C', 'D' => 'D ', 'E' => 'e ',
'F' => 'F', 'G' => 'G', 'H' => 'h', 'I' => 'I ', 'j' => 'J ',
'K' => 'K', 'L' => 'L', 'M' => 'm', 'n' => 'N ', 'o' => 'O ',
'P' => 'P', 'q' => 'Q', 'R' => 'R', 's' =>'s ', 'T' => 'T ',
'U' => 'u', 'V' => 'V', 'W' => 'W', 'x' => 'X ', 'y' => 'y ',
'Z' => 'Z', 'a' => 'A', 'B' => 'B', 'c' => 'C ', 'D' => 'D ',
'E' => 'e', 'F' => 'F', 'G' => 'G', 'H' => 'h ', 'I' => 'I ',

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.