4

Just reading Adding custom instructions to an UnPublish transaction.

Does anyone know if the split between RenderedItem.AddInstruction (for publish) and ITransportHandler (for unpublish) is still the only way to add custom instructions on both a publish and an unpublish in 8.5?

5

Short answer: it is the preferred way, yes.

Longer answer:

  • For unpublish you can only use the ITransportHandler.

  • For publish you can use both the RenderedItem.AddInstruction and ITransportHandler, but it's better to use the AddInstruction because it's an API call and not direct XML manipulation. Note that you can use the RenderedItem.AddInstruction from two places: Templating, or from a Custom Renderer. It depends on your needs.

PS. Some shameless self promoting, but feel free to see my talk from this year's TDS. It's related to your question.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.