I'm struggling to get hold of the culture of an IContent object that does not make use of Language Variants. It's the property shown in the screenshot below. Shouldn't that be available from the database as well? I'm aware that reverting to IPublishedContent could be a workaround, but what if the object is not published yet? It should have a culture anyway (either set or inherited from its parent), shouldn't it?
The domainservice does not return any domains for subnodes; only for the domain root nodes. And to check all the ancestors for IContent will result probally in bad performance.
V8: Culture of IContent object
I'm struggling to get hold of the culture of an IContent object that does not make use of Language Variants. It's the property shown in the screenshot below. Shouldn't that be available from the database as well? I'm aware that reverting to IPublishedContent could be a workaround, but what if the object is not published yet? It should have a culture anyway (either set or inherited from its parent), shouldn't it?
Nobody any idea to point me in the right direction?
I have the same challenge, anyone a idea?
Just guessing, but do you need to use the
DomainService
to get the assigned domains for it?https://our.umbraco.com/apidocs/v8/csharp/api/Umbraco.Core.Services.Implement.DomainService.html
The domainservice does not return any domains for subnodes; only for the domain root nodes. And to check all the ancestors for IContent will result probally in bad performance.
Any luck solving this Jörg?
is working on a reply...