Computer Science Canada

need help for encrypter

Author:  basiblaster [ Tue Dec 17, 2019 8:57 am ]
Post subject:  need help for encrypter

I am trying to create a encrypting program. i am trying to create the letter-number script right now so that i can change the values by a set amount later.

encryption shit
encryption key (10 NUMBERS long):
<input type=text style="width:500px" id="key">
input text (what you want to encrypt):
<input type="text" style="height:200;width:500" id="input">
<input type="button" value="encrypt" onClick=encrypt()>

function encrypt() {
//input from HTML
var key = document.getElementById("key").value ;
var input = document.getElementById("input").value ;
//determin how many times to run the loop
var string = input.length ;
//other vars
var index ;
var output ;
//letter to number loop
while (string<0){

var en1 = input.charCodeAt(index) ;

string-1 ;
index+1 ;

output.push(en1) ;
//write output to HTML
document.getElementById("output").innerhtml=output ;
<p1 id=output>
output goes here!