0

I have created one multimedia component having extension zip.when we are publishing multimedia component I want extract and publish it into deployer with same folder structure. For example we are having a.zip file when we are extraction it will extract - HTML - Images - Css - Js - Media - PDF - Fonts above folders have files. I have created C# TBB and this code have logic for

  • extracting zip file into local folder

  • read one by one folder,create structure group for that folder and publish all files in that folder.

Binary binary = engine.PublishingContext.RenderedItem.AddBinary(ms, "filename", rootStructureGroup, rootStructureGroup.Id, maincomponent, "image/png");

But in deployer it is publishing one file in every folder. Could you please help me in placing all the files in folder.

1

For this scenario, I guess you need to write a Storage Extension (or may be Deployer Extension or Custom Resolver as there may be difference of opinion).

In Storage Extension (or Deployer Extension), you will get an extension point during the Publishing process in which you can write your custom code (in JAVA) to perform the extraction of items of Zip file and deploy them as per your business logic.

You may refer THIS post to get your hands on the Storage Extension.

You may refer THIS post for Custom Resolver

You may refer THIS post for Deployer Extension

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.