The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How do I create a confirmation button?
All I want to do is, 1. Have a button. 2. When clicked on it, it will popup a confirmation box with statement "Are you Sure?" and there will be Yes and No choices to click on. If yes, it runs the script. If no, it will not do anything like they never clicked on it.
I tried doing it but keeps failing: Quote:
Quote:
Quote:
|
#2
|
||||
|
||||
I just do it this way:
HTML Code:
<form action="stuff..." method="post" name="name..." onsubmit="return confirm(\'Are you sure?\');">
|
#3
|
|||
|
|||
Nothing appears when I have that code.
|
#4
|
||||
|
||||
Have what code? I hope you didn't use my exact code because I took out most of the form stuff. If you are going say say something doesn't work, then show us *exactly* what you tried.
|
#5
|
|||
|
|||
Quote:
|
#6
|
||||
|
||||
Well, if what works for me doesn't work for you, have you tried any of the many methods you get when you google "javascript popup confirm"?
|
#7
|
|||
|
|||
Yes, trust me I tried for hours, that's where I got my code to begin since I don't know anything about <form>. I think it has something to do with that page.
Like for example I put this piece of code in a blank php file: PHP Code:
However, when I put that code in my template, when I click the button, it automatically directs me to a page with the false "You pressed Cancel!" text. I think something is interfering with it? |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|