Try our conversational search powered by Generative AI!

Customize content area rendering in MVC templates


I'm looking for the MVC helper equivalents of the Property control's properties used for customizing the rendering of content areas.

In other words, how to set the element and class names of the content area container as well as the individual block containers in MVC templates?

Is this even possible using the PropertyFor helper?


Nov 01, 2012 15:04

Nevermind, sometimes the solution is right in front of you... :)

@Html.PropertyFor(m=>m.MyContentArea, new { CssClass = "row", CustomTag = "section", ChildrenCustomTagName = "article", ChildrenCssClass =  "span4"})


Nov 01, 2012 15:21

Is there now a better solution than forcing ChildrenCssClass that appends to the class?

Could one decide how may blocks/object that fits into a ContentArea?

Aug 09, 2013 15:08
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.