找了很多资料,我也不确认我的方法是不是正确,但是抓包工具和gw返回的头信息是正确的。
This way the URL is always easy to understand for the user. Do not use English URLs for non-English pages, so for a Polish page use "kontakt" instead of "contact". After all, if an URL is to be comprehensible for a visitor, it needs to be in the language he or she has chosen to use.
If you want to inform search engines about the language of the current page, you have three options that you can use in tandem:
- Send the HTTP header Content-Language: xx.
- Use the HTML META section: <meta http-equiv="Content-Language" content="xx" />. Remember that this is obsolete in HTML5.
- Use the ‘lang" attribute in the HTML element. <html lang="xx">
location / {
add_header ‘Content-Language‘ en-US;
}
nginx setting
时间: 2024-10-06 03:37:45