Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Preview
Start a free Courses trial
to watch this video
Let’s start with a high level explanation of what HTML forms and CRUD applications are along with an overview of what you’ll learn in this course.
Prerequisites
To get the most from this course, you should have some familiarity with C#, ASP.NET MVC, and HTML forms. For more information about those topics, check out these Treehouse courses:
Additional Learning
For more information about CRUD applications see this page on Wikipedia.
[SOUND] Can you imagine
if you visited Google and
0:00
you couldn't enter text for your search?
0:05
Or if you were using Facebook and
you couldn't update your status or
0:10
comment on a friend's timeline?
0:14
Fortunately, for us and
0:16
the rest of the world HTMML forms
make these features possible.
0:18
In fact it's difficult to use the web and
not use HTML forms.
0:22
Hi, my name is James and I'm a developer.
0:28
In an earlier Treehouse course we
were able to use ASP.NET MVC to
0:31
build an interesting website.
0:36
But our users couldn't
interact with our content.
0:38
Meaning that they were unable to create,
update or
0:41
delete any of the data that
made up our websites content.
0:45
To give our users that
ability our websites,
0:47
web applications or
web apps need to include HTML forms.
0:51
HTML forms are made up of
a combination of fields and buttons.
0:57
A field typically has a label and
an input element.
1:01
Input elements come in a variety of types,
including text boxes,
1:05
drop-down lists, radio buttons,
check boxes and more.
1:09
Forms also include at least one button,
typically a Submit or
1:16
Save button that when clicked sends the
form data to the server to be processed.
1:20
When we combine a view that
lists the available records,
1:26
along with views to create, update and
1:29
delete records, we're creating a type of
application known as a CRUD application.
1:32
The acronym CRUD stands for
Create, Read, Update and Delete.
1:37
CRUD applications or
apps provide an end-to-end solution for
1:45
creating, reading,
updating and deleting data.
1:50
Given how often users need to perform,
1:54
one or more of those actions on their
data, CRUD apps are very common.
1:55
In this course, we'll be adding
forms to an existing project,
2:01
to create a simple CRUD web app, that
persists data to an in memory data store.
2:05
As we do that, we'll see how
to use Razor to create forms.
2:10
We'll also learn how to update our
controllers to handle form post data.
2:14
Use models with our forms and
2:19
leverage form validation to ensure that
we get good or valid data from our users.
2:21
In a previous Treehouse course we
learned about the in MVC design pattern,
2:28
URL routing, controllers, views,
the Razor syntax and more.
2:32
These course will build upon those skills.
2:38
So if you haven't completed
the prerequisites yet
2:41
be sure to follow the links
in the teacher's notes.
2:44
Are you ready to start building
your own forms using MVC?
2:47
Let's get started.
2:51
You need to sign up for Treehouse in order to download course files.
Sign up