O'Reilly logo

Linux and Unix Shell Programming by David Tansley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

29.5. Introducing the get and post methods

So far we have only displayed output to the screen. To be able to get information from the user we need to use forms, which is why cgi scripting has become so popular. You need the ability to process the user’s input. With forms you can display text boxes, pull down menus and radio buttons.

Once the user has input or selected some information into the form, the user then clicks on send to send the information to a script, a cgi script in our case. How this information can be collected is where get and post come into play.

29.5.1. get method

The default action by any form is the get method. The get method is the one used to retrieve files from static HTML pages.

When a user clicks on submit, the information ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required