Skip to content

Is it possible to insert something into the Content Zone of a particular Content Item? #8404

Answered by remesq
remesq asked this question in Q&A
Discussion options

You must be logged in to vote

It seems like using the ContentItemID I would be able to accomplish what I wanted, but there's two issues with that (as far as I can tell): 1) If I ever delete and create a new content item, I'd have to go back and update the code with the ID; and 2) seemingly, if I inject a shape, then I'd have to keep the .cshtml file in ~/Views or ~/Views/Items instead of ~/Views/ControllerName/ActionName.cshtml, which can get messy.

I wanted to avoid replicating the HTML which I had inserted in the Content Item with Fields/Parts/Zones using Theme templates, but it's likely the only way to go to keep things clean - so I'll just be using a Module and replicating some of the content item code for the for…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by remesq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant