风一样的男孩 发表于 2012-3-18 19:03:22

去除优酷、土豆、迅雷看看等在线视频缓冲广告的方法

其思路是通过修改系统的hosts文件来实现,当然你也可以把它做成批处理来自动执行!

批处理代码如下:
@echo off
title 屏蔽优酷、土豆、迅雷看看等在线视频缓冲广告
color 0A
cls
echo.
echo.
echo屏蔽优酷、土豆、迅雷看看等在线视频缓冲广告www.life80.cn
ping /n 4 127.0.0.1 >nul
cls
copy %windir%\system32\drivers\etc\hosts %windir%\system32\drivers\etc\hosts.bak
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    adcontrol.tudou.com
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    valf.atm.youku.com
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    dcads.sina.com.cn
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    pubstat.sandai.net
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    mcfg.sandai.net
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    biz5.sandai.net
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    float.sandai.net
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    recommend.xunlei.com
>>%windir%\system32\drivers\etc\hosts echo 0.0.0.0    cl.kankan.xunlei.com
REM 刷新DNS缓存
ipconfig /flushdns
cls
echo.
echo操作完毕,正在退出…
ping /n 3 127.0.0.1 >nul
exit


通过以上批处理文件,你可以选将系统原来的hosts文件进行备份,然后把优酷、土豆、迅雷看看等在线广告的网址的DNS设为无效。这样就做到了去除优酷、土豆、迅雷看看等在线视频广告的目的。
还原hosts代码
@del %windir%\system32\drivers\etc\hosts
@ren %windir%\system32\drivers\etc\hosts.bak hosts
@REM 刷新DNS缓存
@ipconfig /flushdns

如何保存为批处理:
将代码用记事本或其它编辑器,另存为.cmd文件即可!

℡╯寂寞、出租 发表于 2012-4-7 15:01:05

没用哦鉴定完毕
页: [1]
查看完整版本: 去除优酷、土豆、迅雷看看等在线视频缓冲广告的方法