Hi all,
I have a page with a prompt window, as I dont want to user to click the 'cancel' button to skip inputting data.
Is it possible to have the 'ok' button ONLY?
Also, can I control the width of the input box?
Hi H2,
The answer is no. You can't customise prompt dialog as it's the standard javascript function.
If you want to do it, I recommend you to create a "fake" dialog html window, with everything set up as you wish (input width and without Cancel button). Then you'll have to pass the value entered to a parent window, search this forum for an answer how to do it.
But I'm sure that you won't be able to avoid visitor skipping the form. Even if it will not have any Cancel button, anyone can close it using common [x] button at the upper right corner that is on any window.
FYI, you can do some fancy prompting customization using VBScript on the client side. Of course, this is only good on IE browsers but if you have script control on the server, you could detect the browser then serve up VBScript for IE users and JavaScript for NS users.
Chances are, you'll get 90% IE users so you may be able to accomplish what you want.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.