Load value in Input box rather than in pop up in Javascript
<p>I had a java script which generate random vlaues in a pop box here is script :-</p>

<pre><code> function cleanup() 
{
  document.forms.pform.le.value = 8;
  document.forms.pform.up.checked = true;
  document.forms.pform.lo.checked = true;
  document.forms.pform.dg.checked = true;
  document.forms.pform.pn.checked = true;
  document.forms.pform.ct.value = "";
  document.forms.pform.rm.value = "";
}

function pass(){
var specials = '!@#$%^&amp;*()_+{}:"&lt;&gt;?\|[];\',./`~';
var lowercase = 'abcdefghijklmnopqrstuvwxyz';
var uppercase = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
var numbers = '0123456789';

var all = specials + lowercase + uppercase + numbers;

String.prototype.pick = function(min, max) {
    var n, chars = '';

    if (typeof max === 'undefined') {
        n = min;
    } else {
        n = min + Math.floor(Math.random() * (max - min));
    }

    for (var i = 0; i &lt; n; i++) {
        chars += this.charAt(Math.floor(Math.random() * this.length));
    }

    return chars;
};

String.prototype.shuffle = function() {
    var array = this.split('');
    var tmp, current, top = array.length;

    if (top) while (--top) {
        current = Math.floor(Math.random() * (top + 1));
        tmp = array[current];
        array[current] = array[top];
        array[top] = tmp;
    }

    return array.join('');
};

var password = (specials.pick(1) + lowercase.pick(1) + uppercase.pick(1) + all.pick(3, 10)).shuffle();


alert(password);
}
</code></pre>

<p>I am using it on a HTMl page like following :-</p>

<pre><code>   &lt;html&gt;
&lt;head&gt;
&lt;script src="Java.js"&gt;&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;p&gt;&lt;input value="Generate" type="button" onclick="javascript:pass()" /&gt;&lt;/p&gt;
&lt;strong&gt;Your New Data&lt;/strong&gt;
&lt;p&gt;&lt;input type="text" id="outbox" name="outbox" size="40" /&gt;&lt;/p&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>Now when anyone click on Generate button it will generate some random data in pop up alert box, i want that instead of popup box script will generate random data in input box provided below button.</p>
