super_dc
07-24-2003, 03:55 AM
I have the following function which is used to encrypt javascript. The function is called with the encrpted code and adds +30 to the ascii value, and hene decodes it to the variable (o). The question how can I pipe this out to the clipboard so I can extract the code. I can use the alert(o) command to pipe the output to an alert box but this can not be extracted as text.
Any ideas
Thanks in advance
function a(s){t="abcdefghijklmnopqrstuvwxyz0123456789 !#$%&'()*+,-./:;<=>?@[]^_`{|}~ABCDEFGHIJKLMNOPQRSTUVWXYZ";o=new String;l=s.length;for (i=0;i<l;i++){n=t.indexOf(s.charAt(i));if(n==-1){o+=s.charAt(i);continue}if(n==0){o+=String.fromCharCode(10);continue}if(n==1){o+=String.fromCharC ode(13);continue}if(n>1){o+=String.fromCharCode(n+30)}}document.write(o)}
Any ideas
Thanks in advance
function a(s){t="abcdefghijklmnopqrstuvwxyz0123456789 !#$%&'()*+,-./:;<=>?@[]^_`{|}~ABCDEFGHIJKLMNOPQRSTUVWXYZ";o=new String;l=s.length;for (i=0;i<l;i++){n=t.indexOf(s.charAt(i));if(n==-1){o+=s.charAt(i);continue}if(n==0){o+=String.fromCharCode(10);continue}if(n==1){o+=String.fromCharC ode(13);continue}if(n>1){o+=String.fromCharCode(n+30)}}document.write(o)}