Creating a poll controller

If we want to start building out our web application, we'll need to start with some of the base structures that are used to receive our incoming connection, make decisions, pull in new data, and reformat/structure out the response to the user. We'll start with the most fundamental of these: the controllers. Our controllers act as the glue between our templates, our database, and the incoming/outgoing connections; they put everything together in a way that the end user's browser or client can understand. To understand how to effectively use controllers, however, we'll need to ensure we understand how controllers are structured and how best to use them!

Get Phoenix Web Development 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.