submit button code

Reply

Join Date: Sep 2006
Posts: 7
Reputation: Little E is an unknown quantity at this point 
Solved Threads: 0
Little E Little E is offline Offline
Newbie Poster

submit button code

 
0
  #1
Sep 25th, 2006
I designed a website for my husband, but I'm having trouble getting the submit button to work the way I want it. I want it to send the customers information to our email address and then to a thank you page. I've been able to get it to send the information to our email address but it doesn't do anything else. I've tried looking on the web for code that will do this, but I don't understand what information goes where. It took quite a while for me to figure out how to setup the button to sent the information to our email address, but that's as far as I've been able to go.

I've tried a redirect code, but the only way I could get it to work is if a set a timer to it. But I don't want to go that way, because what if the customer isn't finish writing yet and then they get redirected before their done. So that didn't work. When I tried it without the timer, nothing happened.

Right now when the customer clicks the submit button, it sends the information to our email address, but nothing changes on the screen. So the customer thinks nothing happen, so they click it again. Some times we get several of the same message.

I've looked at other websites and I see where they used a CGI file. I don't know how to write CGI code. From what I've read it's similar to Pearl. Well I don't know Pearl either.
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 8
Reputation: vonfeldt is an unknown quantity at this point 
Solved Threads: 0
vonfeldt vonfeldt is offline Offline
Newbie Poster

Re: submit button code

 
0
  #2
Sep 27th, 2006
Can we see some code please?
Reply With Quote Quick reply to this message  
Join Date: Nov 2006
Posts: 2
Reputation: rickymartin001 is an unknown quantity at this point 
Solved Threads: 0
rickymartin001 rickymartin001 is offline Offline
Newbie Poster

Re: submit button code

 
0
  #3
Nov 15th, 2006
could you please help me out the coding of submit button you used plaese its urgent




Originally Posted by Little E View Post
I designed a website for my husband, but I'm having trouble getting the submit button to work the way I want it. I want it to send the customers information to our email address and then to a thank you page. I've been able to get it to send the information to our email address but it doesn't do anything else. I've tried looking on the web for code that will do this, but I don't understand what information goes where. It took quite a while for me to figure out how to setup the button to sent the information to our email address, but that's as far as I've been able to go.

I've tried a redirect code, but the only way I could get it to work is if a set a timer to it. But I don't want to go that way, because what if the customer isn't finish writing yet and then they get redirected before their done. So that didn't work. When I tried it without the timer, nothing happened.

Right now when the customer clicks the submit button, it sends the information to our email address, but nothing changes on the screen. So the customer thinks nothing happen, so they click it again. Some times we get several of the same message.

I've looked at other websites and I see where they used a CGI file. I don't know how to write CGI code. From what I've read it's similar to Pearl. Well I don't know Pearl either.
Reply With Quote Quick reply to this message  
Join Date: Jul 2005
Posts: 8
Reputation: vonfeldt is an unknown quantity at this point 
Solved Threads: 0
vonfeldt vonfeldt is offline Offline
Newbie Poster

Re: submit button code

 
0
  #4
Nov 15th, 2006
Never saw code from the original poster. if you are attempting the same thing - and have ANY code, lets have a look! okay?

-chrisv
Reply With Quote Quick reply to this message  
Join Date: Jun 2006
Posts: 263
Reputation: Mushy-pea is an unknown quantity at this point 
Solved Threads: 1
Mushy-pea's Avatar
Mushy-pea Mushy-pea is offline Offline
Posting Whiz in Training

Re: submit button code

 
0
  #5
Nov 18th, 2006
To make a Perl script display a page you have already created, do this:

  1. open(file1, "thanks.html");
  2. @data = <file1>;
  3. close(file1);
  4. $page = join("", @data);
  5. print "Content-type: text/html\n\n$page";

Just make sure your thanks page has a link for the user to get back to the rest of your site.

Steven.
The one question you should not ask when teaching a new language structure is "Do you understand?". Do you understand?
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Perl Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC