Presentation is loading. Please wait.

Presentation is loading. Please wait.

Form Processing Week Four. Form Processing Concepts The principal tool used to process Web forms stored on UNIX servers is a CGI (Common Gateway Interface)

Similar presentations


Presentation on theme: "Form Processing Week Four. Form Processing Concepts The principal tool used to process Web forms stored on UNIX servers is a CGI (Common Gateway Interface)"— Presentation transcript:

1 Form Processing Week Four

2 Form Processing Concepts The principal tool used to process Web forms stored on UNIX servers is a CGI (Common Gateway Interface) script written in PERL. Active Server Page (ASP) code is used to process forms stored on NT servers.

3 What is Unix? Unix is an operating system that is one of the most popular platforms for internet users and web servers.

4 What is a CGI script? Common Gateway Interface International standard for sending data from the server to a script. Scripts are computer programs which process data and cause actions to occur. Scripts are written in a programming language such as Perl, C++, or Visual Basic.

5 PERL CGI scripts are often written in PERL. PERL is the most common language used for CGI scripts because it handles text, files, and simple processing, quickly and efficiently. PERL can also be ported from one platform to another, and best of all it is free found on the web.

6 Your Internet Provider (ISP) Many ISPs provide you with CGI scripts which you can use instead of downloading your own. Spend some time researching your ISPs CGI policy. We will be using a CGI script stored on the gracie server.

7 the mailto: command using the "mailto" command to process form data, is easy for the developer and hard on the customer. there is no feedback that the data has been submitted. The "mailto command" causes the form data to be sent to me as an email message.

8 the mailto: command Within the opening form tag I add the attribute enctype which specifies the encoding format the browser uses before it sends the data to the server. I assign a value of plain/text. Next I add the javascript event handler onSubmit and a value of window.alert Then you create a message which will appear when the form is submitted, which is placed between parenthesis and single quotation marks.

9 CGI script This refers to a CGI script written in Perl which is placed in a gracie directory for use by all CIS students.

10 Hidden Field identifies the email address the form data should be sent to. The hidden field is a field which contains information which the script can access and process, but which the person using the form never sees. Please CHANGE this to your email address

11 Submitted Form (emailed) When you check your email to see if the message arrived. You will see a new message displaying a subject line of "WWW Form Submission". We can Modify this later.

12 Customizing the CGI script The formmail.cgi script allows for extensive customization through the use of "hidden" fields. The name of this field "subject" causes the script to create a unique subject line in the email message.

13 Form extras

14 Form extras This indicates in the email, what browser they were using and their domain.

15 More Hidden Names This allows me to display an html page which I create, after the form is completed. This page replaces the default "thank you" screen.

16 More Hidden Names This code allows me to list areas of the form which must be completed before the form can be submitted. This is case sensitive.

17 Homework Form Processing mailto: 10 points formmail.cgi 10 points formmail.cgi modified (additional hidden fields) 10 points


Download ppt "Form Processing Week Four. Form Processing Concepts The principal tool used to process Web forms stored on UNIX servers is a CGI (Common Gateway Interface)"

Similar presentations


Ads by Google