atmoner / php-pastebin-v3

Php pastebin tool
110 stars 56 forks source link

Disable submit button after click #53

Open knackrack615 opened 9 years ago

knackrack615 commented 9 years ago

You should disable the submit button after its being click to prevent paste spam

This can be done very easely by changing line 90 on /themes/bootstrap/index.html to the following

<input name="submit" type="submit" value="Submit" id="submit" class="btn btn-primary" onclick="kamos()" />

and add at the top of the file this

function kamos(){
    $('#submit').hide();
}

Easy but effective :)