public static MvcHtmlString FieldSetFor(this HtmlHelper helper, Type type, object defaults = null, string legendText = null, object wrapperAttrs = null) { InputFormBuilder builder = new InputFormBuilder(); TagBuilder tag = builder.FieldsetFor(type, defaults, legendText); tag.AttrsIf(wrapperAttrs != null, wrapperAttrs); return(tag.ToMvcHtml()); }
public static MvcHtmlString InputFor(this HtmlHelper helper, Type type, object buttonAttributes = null, object wrapperAttributes = null, object defaultValues = null, string name = null, string labelClass = null) { InputFormBuilder builder = CreateBuilder(type, labelClass); return(builder.FieldsetFor(type, defaultValues, name) .AttrsIf(wrapperAttributes != null, wrapperAttributes) .ChildIf(buttonAttributes != null, new TagBuilder("span").Button(buttonAttributes)) .ToHtml()); }
public static TagBuilder InputFor(this HtmlHelper helper, Type type, object defaultValues = null, string name = null, string labelClass = null) { InputFormBuilder builder = CreateBuilder(type, labelClass); return(builder.FieldsetFor(type, defaultValues, name)); }