Set up the Hosts file to block Baidu and Google's web ads.

Source: Internet
Author: User

Half of the ads on the page are Baidu and Google ads, they have a number of fixed advertising service domain name, we only need to set up our machine's Hosts file, so that these several domain names can not be correctly resolved to block their effect.

Open with Notepad, C:\WINDOWS\system32\drivers\etc\hosts.

Add in Inside

0.0.0.0 googleads.g.doubleclick.net
0.0.0.0 cpro.baidu.com
0.0.0.0 union.baidu.com
0.0.0.0 Cb.baidu.com

Sometimes the domain name of the ad site may change or add new, everyone through the Firefox Firebug (network), or IE press F12 (network), find new ad domain name is what, added to the hosts can be.

Let's look at the effect:

Set before CSDN Forum 3 Baidu Ads:

After setting up, 3 Baidu ads have gone:

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.