Why some page garbled, why some garbled not garbled? A little dizzy.

Source: Internet
Author: User
Take a look at these two pages: http://www.qgren.com/qigong/gongfa/15_30.shtml
The digest appears garbled.

Look at this page again: http://www.qgren.com/qigong/gongfa/15_28.shtml
Abstract no garbled, very normal.

On the website, part of the page is normal, some page summary garbled. I'm a little dizzy.
The program is the DEDECMS,GBK version. My Web Template is also GBK.

The code for the call summary is as follows:
{dede:field.description runphp= ' yes '}
if (@me <> ") @me = '

summary : '. @me. '

';
{/dede:field.description}

Do not know who can solve my doubts, why this?


Reply to discussion (solution)

No, no, no, there are special characters.
? Check it out.

is added to the space, you can delete it
observed that the meta was the same garbled, so it was taken from the meta

$t = get_meta_tags (' http://www.qgren.com/qigong/gongfa/15_30.shtml '); Echo ' garbled: ', $s = $t [' description '], Php_eol;echo ' Restore: ', str_replace (', ', $s);
Garbled: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning, no, no, no? 5 The Chinese overseas Chinese そ to the Song Dynasty そ? Frame W Yuan Qiao multicolored 4 master chip Huan K mow ぶ?j gun province 0⒛ choose d? H Pine glances at the cough? H Shun-down cough
Restore: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning of the No, no, no, no desire Jing when know is a person wins into not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Not to raise the amount of everyone and caries people to raise the amount of everyone and Bo people raise the volume of everyone

Although I see a so-called space, it may be a variation of a Chinese character.
So please check the text and tell the difference

is added to the space, you can delete it
observed that the meta was the same garbled, so it was taken from the meta

$t = get_meta_tags (' http://www.qgren.com/qigong/gongfa/15_30.shtml '); Echo ' garbled: ', $s = $t [' description '], Php_eol;echo ' Restore: ', str_replace (', ', $s);
Garbled: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning, no, no, no? 5 The Chinese overseas Chinese そ to the Song Dynasty そ? Frame W Yuan Qiao multicolored 4 master chip Huan K mow ぶ?j gun province 0⒛ choose d? H Pine glances at the cough? H Shun-down cough
Restore: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning of the No, no, no, no desire Jing when know is a person wins into not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Not to raise the amount of everyone and caries people to raise the amount of everyone and Bo people raise the volume of everyone



Text differences:
Restore: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning of the No, no, no, no desire Jing when know is a person wins into not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Not to raise the amount of everyone and caries people to raise the amount of everyone and Bo people raise the volume of everyone

Text: Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning, no, no, no. When you know it is a man who wins and does not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Do not raise the amount of everyone to take. People are good at raising the amount of everyone sick. People raise the volume of everyone

Find common law, all is a word followed by a period.
Moderator look

No, no, no, there are special characters.
? Check it out.


No, no, no, no special characters, see document. The back is the best.
No, no, no, no. When you know it is a man who wins and does not return.

$t = get_meta_tags (' http://www.qgren.com/qigong/gongfa/15_30.shtml '); $s = $t [' description ']; $n = Strpos ($s, ' desire ') +2; $t = substr ($s, $n); Echo Bin2Hex (' do. When '), Php_eol;echo Bin2Hex ($t), php_eol; $n = Strpos ($s, ' and ') +2; $t = substr ($s, $n); Echo Bin2Hex (' take. People '), Php_eol;echo Bin2Hex ($t), Php_eol;echo str_replace ("," \xa1\xa1 ", $s), php_eol;echo bin2hex ('); And look at the full-width space.
Bea1a1a3b5b1be20a3b5b1d6aacac7c8cbcaa4bdf8b2bbcdcba1a3ced2cbb5b1cbc8cbceaacaa4bdf8b7d6a1a3d7d4b7c7c8e7c0b4a1a3b4cbb6fed3d 0bce4a1a3cbadc4dccfa4d6aaa1a3cac7b9caa1a3b0a2c4d1a1a3c4aab3efc1bfc8cbc8cbb6f8c820a3c8cbc9c6b3efc1bfc8cbc8cbb6f8b220a3c8cb B3efc1bfc8cbc8cba1c8a1a1a3c8cbc820a3c8cbc9c6b3efc1bfc8cbc8cbb6f8b220a3c8cbb3efc1bfc8cbc8cba1 Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning, no, no, no. When you know it is a man who wins and does not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Do not raise the amount of everyone to take. People are good at raising the amount of everyone sick. People raise the volume of everyone? A1A1

Obviously, when you're working with text, you do the processing of replacing full-width spaces with half-width spaces.
This is the root of the problem!

$t = get_meta_tags (' http://www.qgren.com/qigong/gongfa/15_30.shtml '); $s = $t [' description ']; $n = Strpos ($s, ' desire ') +2; $t = substr ($s, $n); Echo Bin2Hex (' do. When '), Php_eol;echo Bin2Hex ($t), php_eol; $n = Strpos ($s, ' and ') +2; $t = substr ($s, $n); Echo Bin2Hex (' take. People '), Php_eol;echo Bin2Hex ($t), Php_eol;echo str_replace ("," \xa1\xa1 ", $s), php_eol;echo bin2hex ('); And look at the full-width space.
Bea1a1a3b5b1be20a3b5b1d6aacac7c8cbcaa4bdf8b2bbcdcba1a3ced2cbb5b1cbc8cbceaacaa4bdf8b7d6a1a3d7d4b7c7c8e7c0b4a1a3b4cbb6fed3d 0bce4a1a3cbadc4dccfa4d6aaa1a3cac7b9caa1a3b0a2c4d1a1a3c4aab3efc1bfc8cbc8cbb6f8c820a3c8cbc9c6b3efc1bfc8cbc8cbb6f8b220a3c8cb B3efc1bfc8cbc8cba1c8a1a1a3c8cbc820a3c8cbc9c6b3efc1bfc8cbc8cbb6f8b220a3c8cbb3efc1bfc8cbc8cba1 Ananda. There are precepts. He is free from heart, and wisdom is known. He precepts from the beginning, no, no, no. When you know it is a man who wins and does not return. I said that Pethins is the winner in the score. From the non-Tathagata. Here's the two. Who can know. is so. Ananda. Do not raise the amount of everyone to take. People are good at raising the amount of everyone sick. People raise the volume of everyone? A1A1

Obviously, when you're working with text, you do the processing of replacing full-width spaces with half-width spaces.
This is the root of the problem!



Or a little garbled, people raise the amount of everyone? More than a weird stuff.

I've tried this piece of code, and I'm just wondering,
Echo str_replace (', ' \xa1\xa1 ', $s);
After this code does not output the thing,?, this strange stuff will not appear.
Conversely, as long as the back output what, such as your code, output a php_eol,?
It's so weird.
  • Related Article

    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.