Why is the <p> not being inserted into my html?
<p>I'm creating a simple messaging system (for learning purposes) where a user enters their passcode or creates one if they don't have one and our message correspondence is stored in an array within another array. Example: you're the 5th user to register, your passcode is the the 5th item in the pass array, and our correspondence is the the 5th array in the logNum array. </p>

<p>I'm wondering if I can use local storage so users can close their browser and still have our correspondence saved and how I would be able to modify the log. But as of now my confirmation paragraph at the bottom is not even being inserted into the document.</p>

<p>I GREATLY appreciate any advice.</p>

<pre><code>&lt;!DOCTYPE HTML&gt; 
    &lt;html&gt;     
        &lt;head&gt;             
            &lt;title&gt;waGwan?&lt;/title&gt;     
            &lt;meta charset="utf-8"/&gt;
            &lt;link rel=stylesheet href=comm.css&gt;&lt;/link&gt;       
        &lt;/head&gt;     
            &lt;body&gt;                              
                &lt;section&gt;
                    &lt;p&gt;enter or create passcode: &lt;input type=text id=passcode&gt;&lt;/p&gt;
                    &lt;input type=button id="button" value="send"&gt;
                &lt;/section&gt;
                &lt;section id="log"&gt;&lt;/section&gt;
                &lt;script type="text/javascript"&gt;
                    var pass[];
                    var logNum=[];
                    document.getElementById("button").onclick=checkPass;
                    function checkPass(){
                        for(i=0;i&lt;pass.length;i++){
                            //if passcode already exists exit
                            if(document.getElementById("passcode").value==pass[i]){
                                break;
                            }
                            //if passcode doesn't equal last existing passcode the passcode is added to the pass array and an array with name passcode is added to the logNum array
                            else if(document.getElementById("passcode").value!==pass[pass.length-1]){
                                pass.push(document.getElementById("passcode").value)
                                logNum.push(var document.getElementById("passcode").value.toString()[]);
                            }
                        }
                        //adds "Works!" to document
                        document.getElementById("log").innerHTML="&lt;p&gt;Works!&lt;/p&gt;";
                    }
                &lt;/script&gt;
            &lt;/body&gt; 
    &lt;/html&gt;
</code></pre>
