Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
Calling all developers! We invite you to provide your input on Feature Experimentation by completing this brief survey.
Not sure cause I haven't tested it before, but I bet it gets the DisplayName attribute for the page(s) added in the AllowedTypes.
It does not work. I just tried to change the DisplayName from "Tag Page" to "Tag-Page" (in case it was the space that did it), but that didn't have any effect.
Maybe it is simply because my TagPage has PageData as base class...?
[ContentType( DisplayName = "Tag Page", GUID = "e36d32f2-34e2-45e7-ae3d-cfe853282f01", Description = "Tag landing page")] [AvailableContentTypes(Availability.None)] public class TagPage : PageData { }
Hm, ok. Might fetch it from the localized xml files then? Is there any reference for the tag page in /Resources/LanguageFiles/ContentTypeNames.xml in your solution?
I don't seem to have that folder. Where in the solution should it be located?
The default location is ~/Resources/LanguageFiles, but the location is configurable in web.config under the localization node
This text is fetch from a language file that is an embedded resource in EPiServer.Cms.Shell.UI.dll. You can change this by adding the following to one of your language files:
<language name="English" id="en"> <episerver> <cms> <widget> <contentreferencelisteditor> <allowedtypes>You can add these types, dude!</allowedtypes> </contentreferencelisteditor> </widget> </cms> </episerver> ...
This will change the text for all content reference list editors though.
Then it does not really solve the problem if one would want more than one reference list?
Ah,
I misunderstood your question.
To change the [Type] values, add localizaed values to your language file. For Your "Tag page", it would be something like:
<contenttypes> <tagpage> <name>Tag page</name> <description>Something something something</description> </tagpage>
Using "DisplayName" does not work for this purpose
Does anyone know how to customize the part where it says “You can add these content types [Type]” in the editor when using a list of content references?
Where does [Type] come from, and how can it be changed?
Mine just says “Page” and it is quite misleading..