⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 getvcount.js

📁 最强的爬虫工程
💻 JS
字号:

var getVCount={strQuery:"",hasRequest:false,extendBase:function(){if(this.hasExtendBase){return true;}if(typeof(hasInitBaseObject)=='undefined'||false==hasInitBaseObject){document.writeln('<scr'+'ipt type="text/javascript" src="http://you.video.sina.com.cn/js/baseOperate/baseObject.js"></scr'+'ipt>');hasInitBaseObject=true;}if(typeof(baseObject)=='undefined'){var me=this;setTimeout(function(){me.extendBase();},100);return false;}var B=baseObject;for(var p in B){var P=this[p];if(B.isNull(P)){this[p]=B[p];}}this.hasExtendBase=true;},getParam:function(){this.strQuery='';var divs=document.getElementsByTagName('SPAN');for(i=0;i<divs.length;i++){if(""!=divs[i].getAttribute('showVCount')&&null!=divs[i].getAttribute('showVCount')){this.strQuery+=divs[i].getAttribute('showVCount')+"x";}}},getCount:function(){if(typeof(baseObject)=='undefined'){var me=this;setTimeout(function(){me.getCount();},100);return false;}else{this.extendBase();}this.getParam();var postUrl="http://interface.video.sina.com.cn/app/count/getFlashCount.php?vid="+this.strQuery+"&action=flash";if(""!=this.strQuery){count=false;me=this;this.requestJs(postUrl,'count',function(temJsonData){me.show(temJsonData);});}},show:function(count){if(""!=this.strQuery){if(typeof(count)!="undefined"&&count!=false){this.showCount(count);}}},showCount:function(count){var obj=eval(count);var divs=document.getElementsByTagName('SPAN');for(i=0;i<divs.length;i++){if(""!=divs[i].getAttribute('showVCount')&&null!=divs[i].getAttribute('showVCount')){var key=divs[i].getAttribute('showVCount').split('-');divs[i].innerHTML=obj[key[0]];}}}};getVCount.extendBase();function getVCountShowProcess(){getVCount.getCount();}getVCount.getCount();

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -