The latest shielding Baidu snapshot method

Source: Internet
Author: User
Sometimes, because the content changes or privacy issues, we often do not want others through the "Baidu Snapshot" method to view some of their own web site, for webmasters, Baidu Snapshot also diverted a large number of the site's traffic, in order to increase the flow of the site or enhance the content of privacy

Sometimes, because the content changes or privacy issues, we often do not want others through the "Baidu Snapshot" method to view some of their own web site, for webmasters, Baidu Snapshot also diverted a large number of the site's traffic, in order to increase the flow of the site or enhance the content of privacy, I used to provide a way to redirect Baidu snapshots to my site. But then Baidu changed the snapshot algorithm, not from the remote server to obtain JavaScript files, so the previous introduction of the shielding method has now expired.

Now I introduce a new method, the principle is roughly the same, we know that the current Baidu Web page snapshot, although not from the remote server crawl JavaScript files, or still will grab the CSS file from the remote server, and through a technique can be implemented in the CSS file page redirection, To control the Web page in the Baidu snapshot, we control the snapshot Redirect to any page address we have made.

For example, if Baidu snapshot cached files for style.css, then we edit this file on the server, add the following statement in the CSS file, you can control Baidu cache snapshot redirection, so as to achieve shielding Baidu Web page snapshot content function.

Body {onload:expression (location.href= ' http://www.williamlong.info/');}


The above statement is tested in IE browser through. Theoretically, according to this method, we can control the content of Baidu's web snapshots to redirect to any one of our designated URLs, or even third party websites. In order to achieve the normal display of the Web page, Baidu Snapshot screen css is very likely to be very small.

This method can also be used to screen snapshots of other search engines such as Google.



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.