Preview Parent Page using Preview button on Child Page
Hi All,
I currently have a website setup where each page has a page components folder and within this page components folder are Documents each with thieir own template.
Upon visiting a page, it will iterate through each "component" in the folder and render each ones' template, using the method @Umbraco.RenderTemplate(component.Id).
This problem arises when I want to make a change to one of these components. If I make a change and then click on the preview button it will display only said components content which is not styled and not in context with the other components of the page.
I can work around this by clicking preview and then visiting the website in another tab and it will have the preview cookie, allowing me to see the changes styled and in context.
This is fine however it would be much more convenient to be able to preview the page straight from the component.
I know the popular template company Uskinned have this feature so I believe it is doable.
Is there a way to change the preview function to show the Parent page preview rather than the component preview?
You could make a content app (https://our.umbraco.com/documentation/Extending/Content-Apps/) and in the angular, using the content service grab the ancestor and build the preview url from that?
Preview Parent Page using Preview button on Child Page
Hi All,
I currently have a website setup where each page has a page components folder and within this page components folder are Documents each with thieir own template.
Upon visiting a page, it will iterate through each "component" in the folder and render each ones' template, using the method @Umbraco.RenderTemplate(component.Id).
This problem arises when I want to make a change to one of these components. If I make a change and then click on the preview button it will display only said components content which is not styled and not in context with the other components of the page.
I can work around this by clicking preview and then visiting the website in another tab and it will have the preview cookie, allowing me to see the changes styled and in context.
This is fine however it would be much more convenient to be able to preview the page straight from the component.
I know the popular template company Uskinned have this feature so I believe it is doable.
Is there a way to change the preview function to show the Parent page preview rather than the component preview?
I am using Umbraco v7.15.3
Thanks, Mitchell
You could make a content app (https://our.umbraco.com/documentation/Extending/Content-Apps/) and in the angular, using the content service grab the ancestor and build the preview url from that?
Hi Ryan,
This is in Umbraco version 7 sorry. It seems that content apps were introduced with v8.
is working on a reply...