HTLM Forms CS3505. Form Handling in Browser html User Files out form WEbBROWSErWEbBROWSEr User read response submit Get URL?input html Get file html script.

Slides:



Advertisements
Similar presentations
WEB DESIGN TABLES, PAGE LAYOUT AND FORMS. Page Layout Page Layout is an important part of web design Why do you think your page layout is important?
Advertisements

Supplement Creating Forms. Objectives Show how forms are used How to create the Form element HTML elements used for creating input fields.
JavaScript Forms Form Validation Cookies CGI Programs.
XP 1 Creating Web Page Forms Designing a Product Registration Form Tutorial 6.
Creating Web Page Forms. Objectives Describe how Web forms can interact with a server-based program Insert a form into a Web page Create and format a.
Tutorial 6 Working with Web Forms
Gathering Requirements What do users want?. Information Gathering Techniques Surveys Interviews Focus Groups.
Form Basics CS Web Data  Most interesting web pages revolve around data  examples: Google, IMDB, Digg, Facebook, YouTube, Rotten Tomatoes  can.
USER INTERACTIONS: FORMS
Tutorial 6 Working with Web Forms. XP Objectives Explore how Web forms interact with Web servers Create form elements Create field sets and legends Create.
CGI Programming: Part 1. What is CGI? CGI = Common Gateway Interface Provides a standardized way for web browsers to: –Call programs on a server. –Pass.
1 CS101 Introduction to Computing Lecture 12 Interactive Forms (Web Development Lecture 4)
Tutorial 6 Forms Section A - Working with Forms in JavaScript.
ECA 228 Internet/Intranet Design I Forms. ECA 228 Internet/Intranet Design I Forms forms are a way for a user to communicate with you – text fields –
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
1 Web Developer & Design Foundations with XHTML Chapter 6 Key Concepts.
4-Sep-15 HTML Forms Mrs. Goins Web Design Class. Parts of a Web Form A Form is an area that can contain Form Control/Elements. Each piece of information.
XP Tutorial 6New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Creating Web Page Forms Designing a Product Registration Form Tutorial.
XP Tutorial 6New Perspectives on HTML and XHTML, Comprehensive 1 Creating Web Page Forms Designing a Product Registration Form Tutorial 6.
CO1552 Web Application Development HTML Forms. Websites can be made more interactive by providing facilities for users to provide data To get user entered.
1 Creating Web Forms in HTML Web forms collect information from customers Web forms include different control elements including: –Input boxes –Selection.
Forms and Form Controls Chapter What is a Form?
CSE 382/ETE 334 Internet and Web Technology Presented By Dr. Shazzad Hosain Asst. Prof. EECS, NSU.
1 Forms A form is the usual way that information is gotten from a browser to a server –HTML has tags to create a collection of objects that implement this.
Chapter 6: Forms JavaScript - Introductory. Previewing the Product Registration Form.
Internet / Intranet CIS-536 Class 7. 2 HTML Forms A Method to Allow Users to Pass Information to a CGI Script Forms Allow Information to Be Entered Via:
1 XHTML Forms A form is the mechanism to –Collect information from a browser user –Transmit collected information from a browser to a server HTML/XHTML.
Robinson_CIS_285_2005 HTML FORMS CIS 285 Winter_2005 Instructor: Mary Robinson.
Introduction to Programming the WWW I CMSC Summer 2004 Lecture 6.
HTML Forms. Today’s Lecture We will try to understand the utility of forms on Web pages We will find out about the various components that are used in.
Website Development with PHP and MySQL Saving Data.
Forms and Server Side Includes. What are Forms? Forms are used to get user input We’ve all used them before. For example, ever had to sign up for courses.
LOGO FORMs in HTML CHAPTER 5 Eastern Mediterranean University School of Computing and Technology Department of Information Technology ITEC229 Client-Side.
1 © Netskills Quality Internet Training, University of Newcastle HTML Forms © Netskills, Quality Internet Training, University of Newcastle Netskills is.
Tutorial 6 Working with Web Forms. XP Objectives Explore how Web forms interact with Web servers Create form elements Create field sets and legends Create.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
Creating Web Page Forms. Introducing Web Forms Web forms collect information from users Web forms include different control elements including: –Input.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 7 TH EDITION Chapter 9 Key Concepts 1 Copyright © Terry Felke-Morris.
HTML Forms a form is a container for input elements on a web page input elements contain data that is sent to the web server for processing.
Introduction To HTML Form Inputs Written By George Gimian.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 9 Key Concepts 1 Copyright © Terry Felke-Morris.
Web Page Design Forms! Website Design. Objectives What forms can do The Attributes of the form tag Using Textboxes Textareas Checkboxes Radio buttons.
+ FORMS HTML forms are used to pass data to a server. begins and ends a form Forms are made up of input elements Every input element has a name and value.
Starting BBEdit or Notepad and Opening the HTML File Start BBEdit or Notepad Select Open from the File Menu Open survey1.htm from the Public Folder.
©SoftMooreSlide 1 Introduction to HTML: Forms ©SoftMooreSlide 2 Forms Forms provide a simple mechanism for collecting user data and submitting it to.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
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)
Project 6 Creating Forms on a Web Page. Objectives Define terms related to forms Describe the different form controls and their uses Use the tag Create.
HTML Creating Forms on a Web Page. 2 Objectives  Discuss the process of creating a form  Distinguish between data input controls and text input controls.
HTML Forms.
Week 10: HTML Forms HNDIT11062 – Web Development.
HTML FORMS Basharat Mahmood, Department of Computer Science,CIIT,Islamabad,Pakistan. 1.
Creating Forms on a Web Page. 2 Introduction  Forms allow Web developers to collect visitor feedback  Forms create an environment that invites people.
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Project 6: Creating XHTML Forms Kelly.
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
1 Web Engineering Forms Lecture 05. FORMS Its how HTML does interactivity. There are quite new feature in HTML5. But the fundamental idea does not change.
HTML FORM. Form HTML Forms are used to select different kinds of user input. HTML forms are used to pass data to a server. A form can contain input elements.
HTML III (Forms) Robin Burke ECT 270. Outline Where we are in this class Web applications HTML Forms Break Forms lab.
HTML Structure II (Form) WEEK 2.2. Contents Table Form.
FORMS Explained By: Jasdeep Kaur. Lecturer, Department of Computer Application, PGG.C.G., Sector: 42, Chandigarh.
Informatics Computer School CS114 Web Publishing HTML Lesson 4.
Ashima Wadhwa Java Script And Forms. Introduction Forms: –One of the most common Web page elements used with JavaScript –Typical forms you may encounter.
XP Tutorial 6New Perspectives on HTML, XHTML, and DHTML, Comprehensive 1 Creating Web Page Forms Designing a Product Registration Form Tutorial 6.
2440: 141 Web Site Administration Web Forms Instructor: Joseph Nattey.
Client-Side Internet and Web Programming
Basic XHTML Tables XHTML tables—a frequently used feature that organizes data into rows and columns. Tables are defined with the table element. Table.
CNIT 131 HTML5 - Forms.
Introduction to HTML: Forms
Presentation transcript:

HTLM Forms CS3505

Form Handling in Browser html User Files out form WEbBROWSErWEbBROWSEr User read response submit Get URL?input html Get file html script In memory Execute script

Simple Form Elements Forms provide a mechanism for collecting user data such as , zip codes, comments and selections. Forms are enclosed in tags and contain code for three basic functions: –1)Tags to define inputs for information –2)Tags to trigger the action –3)Attributes to define the desired action

Simple Form Internet and WWW How to Program - Forms Feedback Form Please fill out this form to help us improve our site. Name:<input name = "name" type = "text" size = "25" maxlength = "30" />

Action Response The action response defining the “do something” is usually a script, other HTML page, or ASP program. A script on the server that executes the action is usually located on the server in /cgi-bin/ –example = “get”*.html, Html File *.asp, Active Server Page *.pl, perl function() J-script in Dom command

CGI Interface How do input values get to the script? The Common Gateway Interface (CGI)is the mechanism by which user input values are passed to the script which executes the desired action. GET method puts values in GO line after the “?” –Good for short input parameters POST method uses a data message –Good for long input such as a page of text

Get vs. Post User Files out form User read response Submit get Get URL?input html Data message file Submit post Get URL html Executable file File executes Read input from STDIN Send response User Files out form User read response Read input from “QUERY_STRING” WEbBROWSErWEbBROWSEr

CGI “GET” Interface Example 1) Form2.html contains Input name statements: 2) Get method puts Named variables in GO line file:///J:/ClassNotes/HTML- Forms/FormExamples/FormActionResponse.html?recipient direct=main.html&name=baer NOTE Format: “&” seperates variable ; “+” spaces

Form Response Architecture script htmlUser Files out form WebBrowserWebBrowser Web ServerWeb Server User read response Other action submitinput To /cgi-bin/script html

Feedback Form3 Example Look at the source for the feedback example … Method – –Server executes formail in directory /cgi-bin Hidden input –<input type = "hidden" name = "recipient“ value = /> User input – inserts a text box --> – Name: – <input name = "name" type = "text" size = "25" – maxlength = "30" /> – Submit –

Basic Input <input type = –Hidden - input to script not supplied by user –Text - inserts a text box –Checkbox- inserts a check box –Radio- inserts a radio button –Password - puts in “****” to protect entry –Submit- starts the action –Reset- deletes previous entries Name = –“input_variable_name” - used to identify the variable Value = –“default value” - value of the variable, often a text string Other = –other attribute such as size = /> close input tag

More Input … multi-line input –<textarea name = "comments" rows = "4" cols = "36"> … pop up select options input – male female other

Complex form example Text Textarea Password Check box Radio box Select Submit/ reset

After you submit Submit packages Input values and sends them to the server Server tries to execute the cgi script referenced with the action attribute If the file is not accessible We get an error. For now we let the action be the display of another page – This is as much as we can do without Server side programming

MailTo Form Most sites including NPS has a MAILTO script available Find out about MAILTO scripts by searching on the internet, there are many options and alternatives The one at NPS using a Microsoft Browser –Uses the GET method –Action is MAILTO: MAILTO: –Input are: cc,bcc,subject,body –There may be others

MailTo Form Look at the example FormsMailTo.html