ASPX templates
Version 5.x > ASPX templates > change template for multiple pages View modes: 
User avatar
Member
Member
ffyy - 3/22/2011 6:46:33 AM
   
change template for multiple pages
I need to change the template for lots of staff profile pages. I've changed the default page template for this document type but for existing pages, their template won't change automatically. It'll take quite a while if I go to each page's property tab and select another template from there.

I've noticed the document listing under parent document. However, one can only do certain actions to documents in the list, which doesn't include changing template.

Can anyone help?

Thanks!

User avatar
Member
Member
ffyy - 3/23/2011 5:16:09 AM
   
RE:change template for multiple pages
Found the solution!

First change the parent page’s template. All the child pages should all inherit the template. For those who don't, click on ‘Inherit template’, then ‘Save’.

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 3/24/2011 1:48:16 PM
   
RE:change template for multiple pages
Hi,

Second option is to create a simple SQL query and run it over the CMS_Document table where you will set the DocumentPageTemplateID column to the page template's ID you want for the document you want.

Best regards,
Juraj Ondrus