4

Is there a way to publish pdf or any other binary files to a specific folders on the website? Part of my site is used for document repository and I need content manager an ability to simply upload/deploy documents.

  • 1
    within your cd_storage_conf.xml where do you currently publish to? broker or filesystem? do you have specific schema designed for .pdf files and/or other binaries? Or is it a one schema fits all type of model for multimedia? if so, do they use a Component Template that is Published as a Dynamic Component? – Andrew William Ross May 12 '15 at 15:40
  • publish to a file system, no specific schema for pdf/or binaries, do have a Component Template that is Published as a Dynamic Component. My pdf/binary files are MM Components. I have a SG folders and subfolders defined and publishing html/text files successfully. Need to publish pdf/binary along with those html files – Michael M May 13 '15 at 17:34
6

Based on your question, it looks like you want to publish binaries to a certain location. You can add configuration in the cd_storage_conf on the deployer to deploy the binaries at any given location.

Step 1: add the new storage under "Storages" assuming you have a different default storage for all other content

<Storage Type="filesystem" Class="com.tridion.storage.filesystem.FSDAOFactory" Id="defaultFile" defaultFilesystem="false"> <Root Path="\\YourDeployLocation" /> </Storage>

Step 2: Configure which files you want to deploy to the above location by specifying the item type mapping under the "ItemTypes" element like:
<Item typeMapping="Binary" itemExtension=".pdf" storageId="defaultFile"/>

After this configuration, all the .pdf files will be deployed to the given location.

  • In my scenario pdf/binary files must be published to different folders either directly or to SG – Michael M May 13 '15 at 19:36
  • You can use the classification path of the asset being referred and create SG in Tridion (if you are referring an asset from an external system via ECL) so that you can use the same while publishing and then deploy to the specific location using the SG. @Dominic in the below answer has also specified option below in his answer – Vipin Kothari May 13 '15 at 20:17
5

The solution is while creating Component Template in Template Builder, select Default Finish Action, click the Parameters tab and select desired SG in Binaries target structure group.

2

The location of published binaries can be specified as a structure group when calling AddBinary. This can get surprisingly complex. There are several articles on the Internet on this subject that can help you to understand what the difficulties can be. My own article on this is published on the Indivirtual Blog, and at the bottom there are links to some others.

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.