HTML Form Widgets. Review: HTML Forms. Review: CGI Programs



Similar documents
<option> eggs </option> <option> cheese </option> </select> </p> </form>

07 Forms. 1 About Forms. 2 The FORM Tag. 1.1 Form Handlers

Further web design: HTML forms

HTML Tables. IT 3203 Introduction to Web Development

Internet Technologies

FORM-ORIENTED DATA ENTRY

Tutorial 6 Creating a Web Form. HTML and CSS 6 TH EDITION

HTML Forms and CONTROLS

XHTML Forms. Form syntax. Selection widgets. Submission method. Submission action. Radio buttons

PHP Form Handling. Prof. Jim Whitehead CMPS 183 Spring 2006 May 3, 2006

By Glenn Fleishman. WebSpy. Form and function

HTML Forms. Pat Morin COMP 2405

Web Design and Development ACS Chapter 13. Using Forms 11/30/2015 1

Designing and Implementing Forms 34

FORMS. Introduction. Form Basics

Dreamweaver Tutorials Creating a Web Contact Form

Web Development 1 A4 Project Description Web Architecture

Inserting the Form Field In Dreamweaver 4, open a new or existing page. From the Insert menu choose Form.

CGI Programming. What is CGI?

CS412 Interactive Lab Creating a Simple Web Form

understand how image maps can enhance a design and make a site more interactive know how to create an image map easily with Dreamweaver

Dynamic Web-Enabled Data Collection

InPost UK Limited GeoWidget Integration Guide Version 1.1

Upload Center Forms. Contents. Defining Forms 2. Form Options 5. Applying Forms 6. Processing The Data 6. Maxum Development Corp.

Forms, CGI Objectives. HTML forms. Form example. Form example...

2- Forms and JavaScript Course: Developing web- based applica<ons

Web Development. Owen Sacco. ICS2205/ICS2230 Web Intelligence

Viewing Form Results

c. Write a JavaScript statement to print out as an alert box the value of the third Radio button (whether or not selected) in the second form.

In order for the form to process and send correctly the follow objects must be in the form tag.

Website Login Integration

ASP.NET: THE NEW PARADIGM FOR WEB APPLICATION DEVELOPMENT

PHP Tutorial From beginner to master

Configuring iplanet 6.0 Web Server For SSL and non-ssl Redirect

Client-side Web Engineering From HTML to AJAX

TCP/IP Networking, Part 2: Web-Based Control

JAVASCRIPT AND COOKIES

ADT: Inventory Manager. Version 1.0

Inspiring Creative Fun Ysbrydoledig Creadigol Hwyl. Web Design in Nvu Workbook 1

FRONTPAGE FORMS

ADT: Bug Tracker. Version 1.0

SQL Injection for newbie

Introduction Designing your Common Template Designing your Shop Top Page Product Page Design Featured Products...

How to Make a Working Contact Form for your Website in Dreamweaver CS3

Introduction to XHTML. 2010, Robert K. Moniot 1

Creating a generic user-password application profile

DNNCentric Custom Form Creator. User Manual

Form Tutorial. Overview. Creating a Form. Insert a Form

Form Management Admin Guide

Qualtrics Question API

payment solutions The DirectOne E-Commerce System Technical Manual

JavaScript By: A. Mousavi & P. Broomhead SERG, School of Engineering Design, Brunel University, UK

jquery Tutorial for Beginners: Nothing But the Goods

JavaScript and Dreamweaver Examples

Working with forms in PHP

Copyright 2008 The Pragmatic Programmers, LLC.

by Jonathan Kohl and Paul Rogers 40 BETTER SOFTWARE APRIL

Overview of CheckMarket question types

Hypercosm. Studio.

This guide shows you how to configure each display option within the item editor.

PloneSurvey User Guide (draft 3)

Using Spry Widgets. In This Chapter

Accessibility in e-learning. Accessible Content Authoring Practices

Basic tutorial for Dreamweaver CS5

CRM Developer Form

Intell-a-Keeper Reporting System Technical Programming Guide. Tracking your Bookings without going Nuts!

Customizing Confirmation Text and s for Donation Forms

Using Form Scripts in WEBPLUS

Overview. How It Works

Documentation. New Registration Start by filling out the easy registration forms to begin creating your new account on the Newsmax Feed Network.

7 The Shopping Cart Module

Tutorial: Building a Dojo Application using IBM Rational Application Developer Loan Payment Calculator

How to do Split testing on your WordPress site using Google Website Optimizer

BT Cloud Voice. Call Forward Selective. What is it? How do I set up a rule?

Introduction to Ingeniux Forms Builder. 90 minute Course CMSFB-V6 P

Real SQL Programming 1

Updating KP Learner Manager Enterprise X On Your Server

NN Markedsdata application installation instruction

4 Understanding. Web Applications IN THIS CHAPTER. 4.1 Understand Web page development. 4.2 Understand Microsoft ASP.NET Web application development

So you want to create an a Friend action

Adobe Dreamweaver CC 14 Tutorial

Web Application Development

Student Records Home Page

Tutorial: Creating a form that s the results to you.

Using Adobe Dreamweaver CS4 (10.0)

Form Mail Tutorial. Introduction. The cgi-bin

Offline Payment Methods

Your Salesforce account has 100 free Force.com licenses that you can activate to run thirdparty applications such as DreamTeam.

Web Hosting Training Guide. Web Hosting Training Guide. Author: Glow Team Page 1 of 22 Ref: GC349_v1.1

Google AdWords TM Conversion Tracking Guide

Creating Web Pages with HTML Simplified. 3rd Edition

User Guide for Smart Former Gold (v. 1.0) by IToris Inc. team

Transcription:

HTML Form Widgets Review: HTML Forms HTML forms are used to create web pages that accept user input Forms allow the user to communicate information back to the web server Forms allow web servers to generate dynamic web pages, and to personalize pages for the individual user Forms contain labels, text boxes, buttons, etc. Review: CGI Programs After the user enters the information, they press the submit button to send the information to the web server The <form action= URL > attribute tells the web browser where to send the information The action URL is the address of a CGI program that is running on a web server The CGI program reads the user input sent by the browser, and then sends a dynamically generated HTML page back to the browser 1

Client-side Scripting Not all HTML forms contact a CGI program on a web server These forms execute entirely on the client computer The program is included as part of the HTML page that contains the form, and is executed by the browser This program is sometimes called a script, and is written in a programming language named JavaScript Many web sites use a combination of CGI programs and client-side scripting Pizza Order Demo Text Box Button HTML Form Widgets Check Box Radio Buttons Text Area Selection List 2

Text Box <input type= text > size (the width of the text box in characters) maxlength (the maximum number of characters the user is allowed to type in the text box) reference the text box from JavaScript) value (the string currently in the text box) Text Box Demo <td><h2>text Box</h2></td> <td>title: <input type="text" size="20" maxlength="30" name="title" value=""></td> Button <input type= button > value (string label on the button) reference the button from JavaScript) 3

Button Demo <td><h2>button</h2></td> <td><input type= button" value= GO! name= go"></td> Check Box <input type= checkbox > checked (if this attribute is present, the box will be checked when the form loads) reference the check box from JavaScript) Check Box Demo <td><h2>check Box</h2></td> <td>us Citizen: <input type= checkbox name= citizen checked= ></td> 4

Radio Buttons <input type= radio > checked (if this attribute is present, the radio button will be selected when the form loads) reference the radio button from JavaScript) NOTE: All radio buttons in the same group must be given the same name Radio Buttons Demo <td><h2>radio Buttons</h2></td> <td> Freshman<input type="radio" name="year" checked=""> Sophomore<input type="radio" name="year"> Junior<input type="radio" name="year"> Senior<input type="radio" name="year"> </td> Text Area <textarea>the value string goes here between the tags</textarea> cols (the width of the text area in characters) rows (the height of the text area) reference the text area from JavaScript) 5

Text Area Demo <td><h2>text Area</h2></td> <td><textarea cols="20" rows="10" name="address">type your address here.</textarea></td> <select> <option>option 1 <option>option 2 </select> Selection List <select> Selection List size (the number of options that should be visible) reference the selection list from JavaScript) <option> selected (if this attribute is present, the option will be selected when the form loads) 6

Selection List Demo <td><h2>selection List</h2></td> <td> <select name="color" size="1"> <option selected="">red <option>green <option>blue <option>cyan <option>magenta <option>yellow </select> </td> Event Handling Now that we have this nice form, there s only one problem it doesn t do anything! Event Handling We add behavior to HTML forms by adding event handlers to widgets An event handler is a little program that is run whenever a particular event occurs in a widget Examples of events: onclick for buttons, onchange for text boxes Example event handler: When this button is clicked, compute the tax and total for the order 7

Event Handling Each type of HTML form widget has event handler attributes The value of an event handler attribute is a JavaScript program that describes the actions to be performed when that particular event occurs in the widget Event Handling Demo <td><h2>text Box</h2></td> <td>title: <input type="text" size="20" maxlength="30" name="title" value="" onchange="window.alert(demoform.title.value)" > </td> <td><h2>button</h2></td> <td><input type="button" value="go!" name="go" onclick="window.alert(demoform.title.value)" > </td> Event Handling We ll learn a lot more about event handling in a future lecture, but first we need to learn the basics of JavaScript programming Once we ve learned about JavaScript, we ll be able to add interesting behavior to our HTML forms 8