C
checksumde
Hi Guys,
i've found a small java script function that simple
decrypts some encodedtext to plaintext.
function decrypt(t,k){
var y=0;
var r='';
t=unescape(t);
for (i=0;i<t.length;i++){
x=k.charCodeAt(y);
x2=t.charCodeAt(i);
if(x!=x2){
r=r+String.fromCharCode(x2^x);
}';x+='else{
r=r+String.fromCharCode(x);
}
y++;
if(y==k.length){
y=0;
}
}return(escape(r));
}
the problem is that i don't have the
encrypt function. i tried it by my own,
but i'm a noob using javascript in this way
can somebody help me to write this
encrypt function?
regards
i've found a small java script function that simple
decrypts some encodedtext to plaintext.
function decrypt(t,k){
var y=0;
var r='';
t=unescape(t);
for (i=0;i<t.length;i++){
x=k.charCodeAt(y);
x2=t.charCodeAt(i);
if(x!=x2){
r=r+String.fromCharCode(x2^x);
}';x+='else{
r=r+String.fromCharCode(x);
}
y++;
if(y==k.length){
y=0;
}
}return(escape(r));
}
the problem is that i don't have the
encrypt function. i tried it by my own,
but i'm a noob using javascript in this way
can somebody help me to write this
encrypt function?
regards