I was wondering if anyone had some extra time on their hands to please lead me in the right direction. I am trying to put a form on my site and I am so stuck right now, it's making me so mad. How in the world do cgi's and perl and whatever else is needed work together??? I am so confused.
I'm not sure how to save my form page and my thank you page and then the pages, files or whatever, where the results go to and I go check them...how do you save those pages????
Firstly what do you want to do with form? Email the contents, insert the contents into a DB, or other.
You need to use the HTML <form> tag it basically works like this:
<form action="page to send form content to" method="POST or GET">
<input type="field type" name="field_name">
When the user clicks the submit button the form data will be sent to the page you have defined in the form action field. How it is sent is defined by POST or GET, POST sends the form data in the http headers making it transparent to the user (but not invisible!) GET sends the content in the url, so in our example above if a user enters hello into the text field and you were using GET the URL would be
Thank you so much for replying to my post. I really appreciate that.
Ok, first off now that you gave me some options on how I want to receive my results, now I'm not sure, I guess I just want the most effective way, but not by email.
The page that i want the results to go to...(I am using cpanel) should I save that page in my cgi-bin folder or my scgi-bin folder? (my cgi-bin folder is in my public_html folder) and do I save that page as:
1. text document
2. html document
3. Perl Script
4. Shell Script
??? I've seen url's with the ending as .cgi
(Also, just to let you know when I go to create that file it says:
Create a file in /home/hernande/public_html/cgi-bin
then it asks to name that file and how.
ok now...I'm not very clear on the get and post and when you started talking about the http headers and making them transparent but not visible, I'm sorry I don't understand all that. But I will tell you this, I'm really not sure if I should use get or post, all I know is that I would like for a thank you page to come up when the user clicks the submit button. And of course how and where do I save that page?
The php you gave me...once again, I don't understand all that. Can you tell me how and where to save that too?
This is a simple form and matching script written in Perl that will collect the information, send an e-mail to you with that information, and then display a 'thank-you' page. You don't really have to worry about the mail sending portion, since you said you don't need it.
You should put the Perl script (.pl or .cgi) in the cgi-bin folder and CHMOD it to 0755. Make sure you upload it in ASCII (text) mode. A decent FTP client is able to do so. The HTML page containing the form must be placed outside of the cgi-bin (and make sure you set the <form> action to the URL of the perl script -- by default it's set to '/cgi-bin/form_mailer.cgi').
Just getting that simple script running as it is should point you in the right direction. If not, post back here.
well thank you very much. i did get some help from stormraven that proved to be very helpful...thank you very much again.
i think i will go to that site and learn some more.
since i'm here though and have gotten this far which is saying alot becuse the form is exactly what i wanted...how do you do 2 or more forms? using php? which is what i used to do my first one at: http://www.hernandez-schuhfamily.com/form.php