Home > front end >  Website coding is utf-8, baidu grab returns the GBK search snapshot shows garbled, want how to deal
Website coding is utf-8, baidu grab returns the GBK search snapshot shows garbled, want how to deal

Time:02-09

My website coding is utf-8, open the page is normal, but baidu spider grab shows the GBK, baidu search web site shows garbled, how to deal with this? Website redesign is GBK before and after revision database, web site all the coding has been replaced by utf-8

& lt; ! PUBLIC DOCTYPE HTML "-////W3C DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" & gt;
& lt; HTML XMLNS="http://www.w3.org/1999/xhtml" & gt;
& lt; head>
& lt; Meta name="viewport" content="width=device - width, initial - scale=1.0, the minimum - scale=0.5, the maximum - scale=2.0, user - scalable=yes"/& gt;
& lt; Meta HTTP - equiv="content-type" Content="text/HTML. Charset=utf-8 "/& gt;


Baidu to return HTTP header:

HTTP/1.1 200 OK
The content-type: text/HTML. GBK charset=
Server: Microsoft IIS/10.0
X - Powered By: PHP/7.0.20
Date: Mon, 6 May 2019 09:15:53 GMT
Connection: close
The Content - Length: 28496

CodePudding user response:


Baidu search shows garbled words above site

CodePudding user response:

Baidu has a cache, we can try some "baidu snapshot" inside, there is a "snapshot" complaints, try after delete snapshot

CodePudding user response:

Hello World reference 2 floor, response:
baidu has a cache, you can try some "baidu snapshot" inside, there is a "snapshot" complaints, delete a snapshot after try
already clear the cache, snapshot also complained for many times, but at the moment or site search shows the code

CodePudding user response:

The last reply complaint once for you, now can see ah

CodePudding user response:

Hello World reference 4 floor, response:
after the last reply complaint once for you, now can see ah
 homepage is no problem, but as shown in figure, the site of caught inside pages are garbled

CodePudding user response:

Head are write wrong, as such, better compatibility, also GBK before my site, now changed to utf-8, no you said problems, baidu grab is normal,

Try to like this:
& lt; ! DOCTYPE html>
& lt; HTML lang="useful - CN" & gt;
& lt; head>
& lt; Meta HTTP - equiv="content-type" Content="text/HTML. Charset=utf-8 "/& gt;
  •  Tags:  
  • IIS
  • Related