Developer forum

Forum » CMS - Standard features » Can't insert global elements

Can't insert global elements

Mikael Conley
Mikael Conley
Reply

Hi.

After upgrading to 9.3.12 we no longer kan insert any global elements anywhere on the site.
We always get the error "Restriction settings for container does not allow it to contain specified item."

The site is built up code first, with items. There are two sections on most pages that have restrictions on what can be inserted, but this does not seen to influence the outcome in any way.
Can someone help out with this?

Capture.PNG

Replies

 
Morten Bengtson Dynamicweb Employee
Morten Bengtson
Reply

The restriction settings for a container is specified in the layout template. These are different from the restrictions you set up on each individual item type.
Can you upload/paste your layout template which includes the container(s)?

 
Mikael Conley
Mikael Conley
Reply

Sure. They are rather complicated so I'll just put in the pertinant parts:

<section class="content content--hero">
    @Model.Placeholder("Hero", "Hero", "items-allowed:HeroRibbonItem,HeroWithTextRibbonItem;unwrap:true")
</section>

<section class="content content--body">
    @Model.Placeholder("Body", "Body", "items-allowed:ArticleRibbonItem,TextRibbonItem,HeroWithTextRibbonItem,NewsletterRibbonItem,BrandingProductRibbonItem,FeaturedProductsRibbonItem,BrandingRibbonItem,FaqRibbonItem,DetailRibbonItem,FeatureExplanationRibbonItem,GalleryRibbonItem,MediaRibbonItem,ReferenceCollectionRibbonItem,VideoRibbonItem,FindDealerRibbonItem;unwrap:true")
</section>

 
Vladimir Shushunov Dynamicweb Employee
Vladimir Shushunov
Reply

Hi Mikael,

I found a bug in this place - registered it to fix in nearest release - 47425

Best regards,
Vladimir

 

You must be logged in to post in the forum