What are HTML Helpers?

Author Topic: What are HTML Helpers?  (Read 2133 times)

Offline beingchinmayTopic starter

  • Trade Count: (0)
  • Jr. Member
  • **
  • Thank You 1
  • Posts: 73
  • Karma: 0
  • Gender: Male
  • I am Chinmay
    • Fat Cutter
What are HTML Helpers?
« on: 03-25-2017, 03:44:18 »
HTML helpers are methods we can invoke on the Html property of a view. We also have access to URL helpers (via the URL property) and AJAX helpers (via the Ajax property). All these helpers have the same goal, to make views easy to author. The URL helper is also available from within the controller.

Most of the helpers, particularly the HTML helpers, output HTML markup. For example, the BeginForm helper is a helper we can use to build a robust form tag for our search form, but without using lines and lines of code:

Code:
Only registered users can see contents. Please click here to Register or Login.


Offline michral86

  • Trade Count: (0)
  • Semi-Newbie
  • *
  • Thank You 0
  • Posts: 11
  • Karma: 0
  • Gender: Female
Re: What are HTML Helpers?
« Reply #1 on: 05-01-2017, 04:27:27 »
HTML Helper is just a method that returns a HTML string. The string can represent any type of content that you want.

For example, you can use HTML Helpers to render standard HTML tags like HTML <input>, <button> and <img> tags etc.

You can also create your own HTML Helpers to render more complex content such as a menu strip or an HTML table for displaying database data.

There are three types of HTML helpers as given below:
1. Inline Html Helpers
2. Built-In Html Helpers
3. Standard Html Helpers

 

Related Topics

  Subject / Started by Replies Last post
1 Replies
4014 Views
Last post 04-21-2010, 16:12:49
by Sevam
8 Replies
6864 Views
Last post 08-19-2015, 01:14:20
by SanviMalhotra
5 Replies
5258 Views
Last post 02-24-2016, 01:11:14
by Shikha Singh
0 Replies
1917 Views
Last post 09-06-2011, 03:42:50
by Walalayo
17 Replies
14591 Views
Last post 11-01-2017, 12:38:07
by lebar.123