DAVID MALAN: Odds are you've at least filled out or even
created a Google form at some point to solicit information from people,
perhaps their name, email address, phone number, information about them
or the like.
And you've perhaps then browsed that data in a Google spreadsheet,
thereby looking at the data that's been saved from the form albeit
in the cloud on Google servers.
For the problem ahead, you're going to implement
your own microcosm of this idea of Google Forms and Google
Sheets in the form of survey.
First you'll implement a route using a flask, web-based application that
solicits information from the user.
What information you solicit is going to be entirely up to you.
But among the user interface mechanisms available to you, of course,
will be text boxes and text areas, checkboxes, select menus,
radio buttons, and perhaps even more.
Moreover you'll have an opportunity to use Bootstrap, the popular CSS
and JavaScript library that just makes your own HTML look
even better right out of the box.
From there, you're going to have to support some validation of those fields
to make sure that the human actually provides the information that you're
requesting.
And once they do submit the form, it's going to be up to you
to actually store that information on the server.
Now we don't have access just yet to a full fledged database--
more on that to come--
but you do have access to CSV files, Comma Separated
values files, which simply store data from users in a simple text
file separating the various fields with commas
and separating the user submissions one row or one line at a time.
Of course, you'll want to be able to browse these survey submissions.
And so you'll also implement a snippet of code a la Google Spreadsheets,
presenting the user with an HTML table or similar structure via which
you, the owner of the form, can actually view those submissions.
Now you're not going to have to implement log in.
You're not going to actually have multiple people needing
to submit this form.
It'll be just one form and one sheet, but together, these
constitute your very own survey.