this.io={};有什么作用?“setPath:”是什么?修改問(wèn)題:為什么不用window.io={};我找不到WebSocketMain.swf文件為什么放在jQuery.io下?this.io={version:'0.6.1',setPath:function(path){if(window.console&&console.error)console.error('io.setPathwillberemoved.PleasesetthevariableWEB_SOCKET_SWF_LOCATIONpointingtoWebSocketMain.swf');this.path=/\/$/.test(path)?path:path+'/';WEB_SOCKET_SWF_LOCATION=path+'lib/vendor/web-socket-js/WebSocketMain.swf';}};try{if('jQuery'inthis)jQuery.io=this.io;}catch(e){try{if('django'inthis&&'jQuery'indjango)django.jQuery.io=this.io;}catch(e){}}if(typeofwindow!='undefined'){//WEB_SOCKET_SWF_LOCATION=(document.location.protocol=='https:'?'https:':'http:')+'//cdn.socket.io/'+this.io.version+'/WebSocketMain.swf';if(typeofWEB_SOCKET_SWF_LOCATION==='undefined')WEB_SOCKET_SWF_LOCATION='/socket.io/lib/vendor/web-socket-js/WebSocketMain.swf';}
this.io = {};什么意思?
慕工程0101907
2019-04-09 20:23:54