Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-18-2005, 04:07 PM   PM User | #1
JoWiGo
Regular Coder

 
Join Date: Mar 2005
Posts: 114
Thanks: 4
Thanked 3 Times in 3 Posts
JoWiGo is an unknown quantity at this point
Popups =/

Hey, I know I'm new to the site and everything, but I hope that wont interfere with the quality of responce I get here...

Anyways, here goes.

I have a website, and want to make a popup on exit, but not a normal popup. I know how to use the onUnload command, but I don't know how to get this type of popup.

Think of an alert box, the standard message box. I want to have that, but with two fields in it; e-mail and name. I have seen it done and know that it is possible, but I don't know HOW it was done. Any hints or suggestions? Thanks in advance...

-Josh
JoWiGo is offline   Reply With Quote
Old 03-19-2005, 04:26 AM   PM User | #2
JoWiGo
Regular Coder

 
Join Date: Mar 2005
Posts: 114
Thanks: 4
Thanked 3 Times in 3 Posts
JoWiGo is an unknown quantity at this point
Really? No one can help me here? Can anyone point me somewhere that can?
-Josh
JoWiGo is offline   Reply With Quote
Old 03-19-2005, 07:44 AM   PM User | #3
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
You cannot expect a response after only 19 minutes. People are not queuing up to attend to your needs.

<script>
a="email";
b="name";
c=a + " " +b;
alert (c);
</script>

Is that what you require?
Philip M is offline   Reply With Quote
Old 03-19-2005, 03:00 PM   PM User | #4
JoWiGo
Regular Coder

 
Join Date: Mar 2005
Posts: 114
Thanks: 4
Thanked 3 Times in 3 Posts
JoWiGo is an unknown quantity at this point
I had only mentioned that as my post had slipped into somewhere in the second page, and usually on most boards when it gets there it get's lost somewhere. If it is not the same on this board, my full apologies.

No, that is not what I need. I need an alert box, whitch has fields in it where you can enter information. I am not trying to display the e-mail and name, I am trying to make a place where they enter this information into the alert box.

I just need a way to place a text input in an alert box. I have seen it done before, but never since that original page. If anyone has any knowledge on this, please let me know.

Then again, if I'm just speaking crazy, let me know too .
JoWiGo is offline   Reply With Quote
Old 03-19-2005, 04:24 PM   PM User | #5
Philip M
Supreme Master coder!

 
Philip M's Avatar
 
Join Date: Jun 2002
Location: London, England
Posts: 17,044
Thanks: 197
Thanked 2,412 Times in 2,390 Posts
Philip M has a spectacular aura aboutPhilip M has a spectacular aura aboutPhilip M has a spectacular aura about
An alert box means what it says - it opens up a dialogue box containing a read-only message. The only response is OK.
A prompt box requests information to be entered by the user, but only one variable at a time. Responses are OK and Cancel.
Are you in fact seeking to make some sort of pop-up window which has a form with HTML textbox(es) in? If so there are many examples in this forum - try search. But why only when the page is closed?

Last edited by Philip M; 03-19-2005 at 04:45 PM..
Philip M is offline   Reply With Quote
Old 03-20-2005, 04:09 PM   PM User | #6
JoWiGo
Regular Coder

 
Join Date: Mar 2005
Posts: 114
Thanks: 4
Thanked 3 Times in 3 Posts
JoWiGo is an unknown quantity at this point
Ignore the on close part, let's get this part sorted out first.

I was saying it looked like an alert box, i don't know what it was called. But I want to be able to put a form (2 text inputs) into a prompt box, alert box, whatever it looks like.

I have come across another example. As I logged onto my computer this morning my MSN messenger logged in and a popup came up asking me to upgrade to the newest version. It had 2 radio buttons (yes and no) and a check box (don't remind me for a week) on it, with 2 different confirmation buttons (submit, tell me more).

Picture something like this if you will:

Code:
 
|---------------------------------------------|
|  (Java-script application)                 X|
|---------------------------------------------|
|             My text here                    |
|                                             |
|     Name: [INPUT BOX=================]      |
|                                             |
|     Email: [INPUT BOX=================]     |
|                                             |
|      [submit] [no thanks]                   |
|---------------------------------------------|
Something like that above. NOT a pop-up with another webpage inside of it, but a gray background, blue title bared, (javascript application) titled alert box, prompt-box, message box, whatever.

Last edited by JoWiGo; 03-20-2005 at 05:14 PM..
JoWiGo is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:15 PM.


Advertisement
Log in to turn off these ads.