Candor.Web.Mvc.MvcTagHtmlHelperExtension.BeginTag C# (CSharp) Method

BeginTag() public static method

Begins a new tag of any kind. For use in a using statement, allowing other code inside the tag.
public static BeginTag ( this htmlHelper, string tagName, object>.IDictionary htmlAttributes ) : MvcTag
htmlHelper this
tagName string
htmlAttributes object>.IDictionary
return MvcTag
        public static MvcTag BeginTag(this HtmlHelper htmlHelper, string tagName, IDictionary<string, object> htmlAttributes)
        {
            TagBuilder tagBuilder = new TagBuilder(tagName);
            tagBuilder.MergeAttributes(htmlAttributes);

            htmlHelper.ViewContext.Writer.Write(tagBuilder.ToString(TagRenderMode.StartTag));
            MvcTag theTag = new MvcTag(htmlHelper.ViewContext, tagName);

            return theTag;
        }

Same methods

MvcTagHtmlHelperExtension::BeginTag ( this htmlHelper, string tagName, object htmlAttributes ) : MvcTag
MvcTagHtmlHelperExtension