1 00:00:00,000 --> 00:00:00,310 2 00:00:00,310 --> 00:00:02,643 DAVID MALAN: Odds are you've at least filled out or even 3 00:00:02,643 --> 00:00:05,650 created a Google form at some point to solicit information from people, 4 00:00:05,650 --> 00:00:09,100 perhaps their name, email address, phone number, information about them 5 00:00:09,100 --> 00:00:09,920 or the like. 6 00:00:09,920 --> 00:00:13,060 And you've perhaps then browsed that data in a Google spreadsheet, 7 00:00:13,060 --> 00:00:16,420 thereby looking at the data that's been saved from the form albeit 8 00:00:16,420 --> 00:00:18,070 in the cloud on Google servers. 9 00:00:18,070 --> 00:00:20,070 For the problem ahead, you're going to implement 10 00:00:20,070 --> 00:00:22,840 your own microcosm of this idea of Google Forms and Google 11 00:00:22,840 --> 00:00:25,090 Sheets in the form of survey. 12 00:00:25,090 --> 00:00:29,110 First you'll implement a route using a flask, web-based application that 13 00:00:29,110 --> 00:00:30,850 solicits information from the user. 14 00:00:30,850 --> 00:00:33,880 What information you solicit is going to be entirely up to you. 15 00:00:33,880 --> 00:00:36,940 But among the user interface mechanisms available to you, of course, 16 00:00:36,940 --> 00:00:41,120 will be text boxes and text areas, checkboxes, select menus, 17 00:00:41,120 --> 00:00:42,940 radio buttons, and perhaps even more. 18 00:00:42,940 --> 00:00:46,150 Moreover you'll have an opportunity to use Bootstrap, the popular CSS 19 00:00:46,150 --> 00:00:49,630 and JavaScript library that just makes your own HTML look 20 00:00:49,630 --> 00:00:51,880 even better right out of the box. 21 00:00:51,880 --> 00:00:55,078 From there, you're going to have to support some validation of those fields 22 00:00:55,078 --> 00:00:58,120 to make sure that the human actually provides the information that you're 23 00:00:58,120 --> 00:00:58,870 requesting. 24 00:00:58,870 --> 00:01:01,480 And once they do submit the form, it's going to be up to you 25 00:01:01,480 --> 00:01:04,420 to actually store that information on the server. 26 00:01:04,420 --> 00:01:07,300 Now we don't have access just yet to a full fledged database-- 27 00:01:07,300 --> 00:01:08,410 more on that to come-- 28 00:01:08,410 --> 00:01:11,680 but you do have access to CSV files, Comma Separated 29 00:01:11,680 --> 00:01:15,250 values files, which simply store data from users in a simple text 30 00:01:15,250 --> 00:01:18,130 file separating the various fields with commas 31 00:01:18,130 --> 00:01:22,285 and separating the user submissions one row or one line at a time. 32 00:01:22,285 --> 00:01:25,160 Of course, you'll want to be able to browse these survey submissions. 33 00:01:25,160 --> 00:01:29,140 And so you'll also implement a snippet of code a la Google Spreadsheets, 34 00:01:29,140 --> 00:01:32,950 presenting the user with an HTML table or similar structure via which 35 00:01:32,950 --> 00:01:35,678 you, the owner of the form, can actually view those submissions. 36 00:01:35,678 --> 00:01:37,720 Now you're not going to have to implement log in. 37 00:01:37,720 --> 00:01:39,820 You're not going to actually have multiple people needing 38 00:01:39,820 --> 00:01:40,870 to submit this form. 39 00:01:40,870 --> 00:01:43,420 It'll be just one form and one sheet, but together, these 40 00:01:43,420 --> 00:01:46,740 constitute your very own survey. 41 00:01:46,740 --> 00:01:48,227