The forum of the forums

Would you like to react to this message? Create an account in a few clicks or log in to continue.
The forum of the forums

    security password pop up coding

    avatar
    voorm
    New Member


    Posts : 2
    Reputation : 1
    Language : english

    Solved security password pop up coding

    Post by voorm September 8th 2012, 11:08 pm

    Hello.
    For begining i must say I'm low in coding.
    I noticed that its posible to add security pass.I tryed by myself(using http://www.zubrag.com/tools/html-password-protector-encoder.php)but after cancel or ok on empty,i can see what i should not see.
    (after entering into forum geting pop up pass,see picture)

    security password pop up coding Untitl10

    Here's code what i used:
    <script language="JavaScript1.2">
    <!--


    function get_password() {
    orig_pass = prompt("Please enter security password","");
    if (orig_pass!=null && orig_pass!="")
    password = new Array(orig_pass.length);
    for(i=0; i<orig_pass.length; i++) {
    password[i] = orig_pass.charCodeAt(i);
    }
    return password;
    }

    password = get_password();
    orig = unescape("http%3A//theblackleague.forumotion.bz/");
    orig = orig.split("");

    passnum = orig.length % password.length;
    for(i=orig.length-1; i>=0; i--) {

    passnum--;
    if (passnum == -1) passnum = password.length - 1;

    pos1 = i;
    pos2 = i + password[passnum];

    if (pos2 >= orig.length) continue;

    char1 = orig[pos1];
    char2 = orig[pos2];

    orig[pos2] = char1;
    orig[pos1] = char2;

    }

    orig1 = "";
    for(i=0;i<orig.length;i++) {
    orig1 = orig1 + orig[i];
    }
    orig1 = orig1.replace(/mmm/g,"\r\n");

    document.write(orig1);

    //-->

    </script>
    <noscript>JavaScript must be enabled in your browse in order to see protected page.</noscript>

    I hope for some help,where i do wrong,what i need do(how to make to after typing wrong code user can see nothing)



    Last edited by voorm on September 9th 2012, 12:39 am; edited 1 time in total
    avatar
    voorm
    New Member


    Posts : 2
    Reputation : 1
    Language : english

    Solved Re: security password pop up coding

    Post by voorm September 9th 2012, 12:34 am

    Yes,It is it.
    Tnx for good reply.

      Current date/time is September 23rd 2024, 1:15 pm