Skip to main content

Creating and Using Forms

  • Chapter
  • First Online:
PHP and MySQL Recipes
  • 2620 Accesses

Abstract

HTML Forms have many usages, ranging from a simple contact form to a way to collect and edit data in a web-based application. Forms can be created as a static section of HTML or it can be dynamically generated with PHP based on a set of data from a database or another source. No matter how the form is generated it's good practice to validate the input before the form is submitted. This will help prevent data errors and the user will be able to correct errors without having the data sent to the server for validations. It is also necessary to validate the contents of the POST request before data is inserted into the database or otherwise used on the server.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

eBook
USD 16.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 59.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2016 Frank M. Kromann

About this chapter

Cite this chapter

Kromann, F.M. (2016). Creating and Using Forms. In: PHP and MySQL Recipes. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-0605-8_13

Download citation

Publish with us

Policies and ethics