Here you will learn about HTML Helpers. HTML helper is just a method which generates elements. This element represents the content which we want to add in HTML.
Below is the format of using HTML helpers in ASP.NET MVC framework:-
There are many more examples of HTML helper which are used in ASP.NET.
There are 3 type of HTML helpers:-
Inline HTML Helper- The syntax of inline helper is @helper. It makes the code more readable.
Built-In HTML Helper- This is extension method in HTML Helper class. It provide the most common type of HTML element. For e.g- Textarea, checkbox, password etc.
Custom HTML Helper- This method is created by using extension method or by creating static method.
0 Comment(s)