tag:help-archives.hannonhill.com,2010-02-09:/discussions/how-do-i/359-publish-trigger-xml-configurationCascade CMS: Discussion 2011-06-02T20:45:11Ztag:help-archives.hannonhill.com,2010-02-09:Comment/57141502011-03-03T18:51:35Z2011-03-03T18:51:35Zpublish trigger xml configuration<div><p>Hi,</p>
<p>To elaborate further, the information we need to be able to pass
in the XML configuration file is the published site's name, logged
in user who generated the publish request, and the published file
names and paths.</p>
<p>Is it possible to pass this dynamic information from the config
file to the custom publish trigger? If so, how? Are there any
examples of this?</p>
<p>Hopefully this helps clarify our situation. Please let me know
if you have any questions.</p>
<p>Thanks again!<br>
Casey</p></div>caseywtag:help-archives.hannonhill.com,2010-02-09:Comment/57141502011-03-09T20:32:05Z2011-03-09T20:32:05Zpublish trigger xml configuration<div><p>Hi Casey,</p>
<p>It is not possible to get the Site name or the name of the user
publishing.</p>
<p>It will be complicated to figure out he published file names and
paths. In order to get this information, you would need to perform
a Read on the asset being published (you can get the ID and type of
the entity from the <em>PublishTriggerInformation</em> provided to
the publish trigger) using the regular Cascade API. You could then
read the page configuration being published (Page Configuration ID
is also contained in the trigger info) to figure out the file
extension which would have been appended to the page.</p>
<p>The Destination and Transport information also come from the
trigger info object, so those could be read as well.</p>
<p>The Site of the asset being published can be determined by
getting the Site ID of the asset after reading the asset using the
API.</p>
<p>You may be interested in taking a look at the DocX Publish
Trigger available <a href=
"https://github.com/hannonhill/Docx-Publish-Trigger">here</a>. I
believe it does something similar in terms of reading an asset from
the server after it has been published.<br></p>
<p>Let me know if you have further questions.</p>
<p>Thanks!</p></div>Tim