CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner:
Message Box



Jul 25, 2001, 3:21 PM

Post #1 of 3 (475 views)
Message Box Can't Post


I hope somebody can help me.

After analyzing the data of a form I don't want to create a new html-page.
I just want to show a message box with a message depending on the data.

Is that actually possible?
Is it possible to send the javascript command 'alert()' somehow?

Thanx for your help!



Jul 25, 2001, 6:05 PM

Post #2 of 3 (468 views)
Re: Message Box [In reply to] Can't Post

Well i dont know about alert but one thing you can do is make the submit button have target="_blank" and when they submit a new window pops up and you could print in it like your stuff was submitted or whatever. thats the only way i am aware of.

Hope that helps... :)

@letters = ('A'..'Z', 'a'..'z', '1'..'5', '_');
@i = ( '15', '43', '40');
print @letters [ @i, -1, 55];


Jul 26, 2001, 8:43 PM

Post #3 of 3 (453 views)
Re: Message Box [In reply to] Can't Post

Well here is a very simple way to try it

add this to your submit input tag:

where YourMessage is obviously what ever you want to say.


<input ="subit" value="Subit!" onClick="alert('Thank you for filling out the form. I appreciate your taking the time to fill this out. You will now be sent back to our main page!')";>

This will open an alert box after the user clicks submit. The user will have to click the "OK" button before the browser will continue.

If you are using a or E-mail pm, you can probably set a url to go to after submission. You could put your index.htm(l) and then after the user submits, they will get the alert, then after they click "OK", they will be sent back to the main page.

This is a simple JavaScript. This will work just fine if you are making an HTML file with the form that submits the information to a cgi. But if you are programming the cgi itself to have the form, then make sure you put "\" before quotes if you need them. This can very easily cause lethal errors to your script.

I hope that this will help you. I can try to help you further or implement some other ideas if you need them. But this was as close as I could come to what you asked for off the top of my head. Good luck



Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives