Don't miss out Virtual Happy Hour this Friday (April 26).

Try our conversational search powered by Generative AI!

How to add properties to the start page?

Vote:
 

Hi,

I need to modify the home page to have more properties. We have a Home Page content type. I have added the fields, but I don't see them when I run the applications. What should I do so that I can actually see the new properties?

I suspect the answer is super easy, but I haven't had luck finding the solution.

#145136
Feb 25, 2016 17:07
Vote:
 

You can follow this guide to add properties 

http://world.episerver.com/blogs/Alexander-Haneng/Dates/2012/7/How-to-define-properties-in-EPiServer-7---A-quick-reference/

If you are using example site with alloy you can then just use html.propertyfor extension to output them. Check alloy site for example...

Also remember to use virtual on properties otherwise episerver can't fill them and you will get null values back.

#145138
Feb 25, 2016 17:56
Vote:
 

Thanks! It was the virtual that got me :)

#145139
Feb 25, 2016 17:58
Vote:
 

That one gets me still sometimes too. :)

After 10 years of Episerver coding. Kind of embarrassing really..

#145154
Feb 25, 2016 21:53
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* 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.