Recommended: How to count link clicks If you want to count the number of clicks on each domain name of a friendly link, because we cannot operate the web page of the friendly link and cannot write code on the link page, then what should we do? The method is to create a JavaScript functiona(bb){}, and the hyperlink that wants to count the number of clicks is written as ahref=http://www.chinaz.comonclick=aa(2
The purpose of web page redirection is very simple, which is to switch from one page to another when the user or system needs it. The status codes of HTTP during redirection are generally one of 200, 301, and 302. The following lists the status codes. What happens, and then explain the differences between the status codes:200 normal state, nothing happened, ordinary page browsing is usually 200
301 Permanently Moved, a must-use SEO move, which will transfer the PR and other information of the old page to the new page
302 Temporarily Moved, a very common move, and it is also the easiest way to be judged for cheating in SEO.
Jump of status code 200:
1.<metahttp-equiv=refreshcontent=3;URL=default.aspx/>
2.Server.Transfer(default.aspx);
3. URLRewrite--Strictly speaking, this is not a jump, it is just a URL spoof
4.<a>--I wonder if anyone has any opinions if I listed this tag as a jump
Jump of status 302:
Response.Redirect(default.aspx);
Jump of status 301 and : Response.Status=301MovedPermanently;
Response.AddHeader(Location, http://www.code-123.com);
For users, each jump is almost the same and can achieve the goal. But for SEO, these are far behind. The third use of state 200 is very beneficial to SEO, but the first and state 302 of state 200 are basically not beneficial. Then, unfortunately, the 302 jump is Used all over the street.
A long time ago, search engines were still very stupid at that time. Many people used metarefresh to obtain powerful SEO effects, but later they were directly killed by search engines. Later, many people started using 302 as a springboard, and were later killed, such as those two famous cases: Business.com and BMW. The consequences of cheating search engines are very serious. So now few people do SEO on jumps, but some inevitable jumps still need to exist. How to prevent these jumps from having a negative impact? So someone studied 301 jump.
By the way, many websites will have a custom error page when making mistakes, but unfortunately, many people forget this status code. They usually make an error page of 200. Search engines will include this page, but When many 404s of different URLs are redirected to this page, they will be considered to be a large number of duplicate pages. The worst thing is that there are too many 404s, which are considered invalid on the site and too much duplicate content. Therefore, remember to return when making custom error pages. Go back 404.
Share: Talk about the very practical code of asp I have collected some practical asp code, which saves everyone's time to search during web page creation. Filter characters: FunctionGetSafeStr(str) GetSafeStr=Replace(Replace(Replace(Replace(Replace(Replace(Str,','),,"),),),,lt;),gt;) EndFunction Gregorian to Lunar calendar % FunctionNongli(