The CGI Version
In addition to the command-line and GUI versions, a CGI version of the program is created. Figure 15.3 shows the basic screen.
Figure 15.3. Basic CGI screen.
Note that four buttons are on this screen:
Update List— Clicked after the user has changed categories to update the list of disks displayed.
Add— Brings up a new form that lets the user add a disk.
Remove— Removes a disk.
Modify— Modifies a disk.
Each of these buttons is named SUBMIT. The value of the button ("Add", "Remove", "Modify", and "Update List") determines what the program does and which form it displays next.
Thus the program starts off with a large if/else
Get Perl for C Programmers now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.