Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Events System - Possible to publish another page when page is being published?

Tags:

tridion

I have a question about the events system in Tridion 2011.....would it be possible to publish another page when other pages are sent to the publishing queue?

We currently have an XML file that defines our site navigation and sitemap, but unfortunately currently needs manually publishing each time a new page is added to the website.

My concern I have about auto-publishing from the events system as well is having to publish the same page several times, when really it would only need publishing after the final item in the publishing queue has ended its transaction.

like image 493
Richard Read Avatar asked Aug 02 '12 15:08

Richard Read


1 Answers

Whenever you want to change how many items are being published by Tridion in response to a publish action, my mind immediately screams custom resolver.

Chris Summers did a great write up of his experience with them a while ago: http://www.tridiondeveloper.com/the-story-of-sdl-tridion-2011-custom-resolver-and-the-allowwriteoperationsintemplates-attribute

Nuno wrote his experience up a bit more concisely: http://nunolinhares.blogspot.com/2011/10/tridion-publisher-and-custom-resolvers.html

It sounds to me like you should simply add your navigation to the ResolvedItems collection there. If you use resolvers consistently, you also won't get this explosion of publish transactions that you seem worried about and instead will have all related items published (and deployed) in a single transaction.

like image 71
Frank van Puffelen Avatar answered Sep 30 '22 10:09

Frank van Puffelen