The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Lock submit button
I want the "Submit new thread" and "Preview Post" button to lock whenever someone clicks it. I found some JavaScript for a generic form on the internet and tried to get it to work with vBulletin.
The original code was:<script language="JavaScript"> function dis(obj) { for(i=0;i<obj.length;i++) if(obj.elements[i].type == "submit" || obj.elements[i].type == "reset") obj.elements[i].disabled = true; } </script>[/code]I changed that too:[code]<script language="JavaScript"> function dis(obj) { for(i=0;i<obj.length;i++) if(obj.elements[i].type == "submit" || obj.elements[i].type == "preview") obj.elements[i].disabled = true; } </script> I then added the following just after my body tag: Code:
<form onsubmit="return dis(this)"> http://localhost/forums/newreply.php...52&attachment= and the post is never submitted. Any ideas? |
#2
|
|||
|
|||
Its pulling other javascript with it when it submits. Ill see if i can tweak it a bit for you.
|
#3
|
||||
|
||||
cool, thanks
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|