110 likes | 248 Views
Web Interfaces, Forms & Databases. Databases Snyder p351-389 HTML Basics Snyder p89-115 JavaScript Snyder Chapter 18. Online Resources. SQL http://www.sql.org/ HTML Forms http://www.w3schools.com/html/html_forms.asp JavaScript http://www.w3schools.com/js/js_intro.asp. Concepts.
E N D
Web Interfaces, Forms &Databases Databases Snyder p351-389 HTML Basics Snyder p89-115 JavaScript Snyder Chapter 18
Online Resources • SQL • http://www.sql.org/ • HTML Forms • http://www.w3schools.com/html/html_forms.asp • JavaScript • http://www.w3schools.com/js/js_intro.asp
Concepts • A Form is your user interface • It includes basic form elements • textbox • radio buttons • check boxes • submit buttons • etc.
Form Submission • Typically, a form must have a submit button • But you can configure a form to submit upon hitting enter • You can specify an action that will occur if the form is submitted. • In this class, we are going to learn about two types of actions.
Form Actions <form method="post" action="insert.php"> • FYI, the method can be “post” or “get,” the only difference is how the information is sent back to the web server. • The action is what is most important • The action specifies what the form will actually do!
Form Actions <form method="post" action="insert.php"> Actions • call a php, asp, or jsp program (processing done on server) • on some servers you can even call a perl program or even a C++ program • call a JavaScript function (processing done on client computer, the web browser actually does the processing).
Server-side Processing • When your form invokes a php, jsp, or asp program, the web server actually runs the program. • What kind of problems could this cause? • Why is this necessary?
Power of Server-side Processing • A server-side program (a php program for instance) can be very robust. • For example, php • has the full power of a programming language like C++ • has the ability to interface with a database through mysql extentions • For example, asp • has the full power to interface will all sorts of Microsoft servers and software.
Why Client-Side Processing? • Some processing can be done by the client (user’s) computer. • Puts less burden on the web server or application server. • Quicker response • Examples: • Flash movies are processed on the client side • Form validation can be done client side • JavaScript is the leading language used to do client-side processing
Web Interface Problems • Typical Computer Interfaces (take Excel for example) can do a lot. • The interface is truly dynamic • It refreshes constantly • It’s installed locally and can use your computer’s full resources. • Web Interfaces are intrinsically limited • by the Web Browser • and because resources aren’t locally available.