2010-05-06 3 views
-1

나는 브라우저 정보를 얻기 위해 자바 스크립트 코드를 사용한다. 마이크로 소프트 윈도우즈 XP에서 제대로 동작하지만 마이크로 소프트 윈도우즈 서버 2003에서는 작동하지 않는다. 내 코드는 folowing이다. plz 도움.Zeroclipboard 문제

<html> 
    <head> 
    <script type="text/javascript" src="zeroclipboard/ZeroClipboard.js"></script> 

     <script type="text/javascript"> 
      window.onload = function F() { 
       var today = new Date(); 
       var the_date = new Date("December 31, 2012"); 
       var the_cookie_date = the_date.toGMTString(); 
       var the_cookie = screen.width +"x"+ screen.height; 
       var the_cookie = "Screen Resolution:"+the_cookie + ";\nExpires:" + the_cookie_date+";\n Browser CodeName:"+navigator.appCodeName+";\n Browser Name: " + navigator.appName+";\n Browser Version: " + navigator.appVersion+";\n Browser Version: " + navigator.appVersion+"; \n Cookies Enabled: " + navigator.cookieEnabled +";\n Platform: " + navigator.platform+";\n User-agent header: " + navigator.userAgent; 
       /

       document.getElementById('box-content').value=the_cookie; 
      } 





     </script> 
    </head> 
    <body> 


<textarea name="box-content" id="box-content" rows="10" cols="70"> 
</textarea> 
<br /><br /> 
<p><input type="button" id="copy" name="copy" value="Copy to Clipboard" /></p> 

    </body> 
</html> 
<script type="text/javascript"> 
     //set path 

     ZeroClipboard.setMoviePath('http://192.168.101.135:471/browserinfo/zeroclipboard/ZeroClipboard.swf'); 
     //create client 
     var clip = new ZeroClipboard.Client(); 
     //event 
     clip.addEventListener('mousedown',function() { 
      clip.setText(document.getElementById('box-content').value); 
     }); 
     clip.addEventListener('complete',function(client,text) { 
      alert('text is copied'); 
     }); 
     //glue it to the button 
     clip.glue('copy'); 
    </script> 
+1

어떤 일이 발생하거나 또는 어떤 일이 발생하지 않나요? 어떤 오류 메시지가 나타 납니까? –

+5

나는 그것이 작동한다는 것을 알고 있지만, ''컨테이너가 닫힌 후에 *

0

또는 플래시가 없거나 서버 컴퓨터에서 192.168.101.135에 액세스 할 수 없습니다.