5

I have followed SDL documentation for SDL Contextual Image Delivery and have done the below steps.

  1. Installing the API Server Role as a .NET Web application
  2. Installing the Image Transformation Handler in a .NET Web application
  3. Installing Context Engine Cartridge

I have provided img element in the page as follows

<img src="mywebsite.com/cid/scale/100/source/http://myImageWebsite.com/Images/someImage.jpg">

I also tried

<img src="mywebsite.com/cid/scale/100/source/source/Image/someImage.jpg">

when I load the page the folders with path /cid/scale/100/source/ gets created automatically in my web application but the cropped image is not generated.

Please let me know if I am missing anything.

Thanks, Sunil

  • Your second URL looks very odd indeed (with two /source/'s and no s in \Image\. Have you confirmed you can get the images without any transformations first? ... e.g <img src="http://mywebsite.com/cid/mywebsite.com/Images/someImage.jpg"> or similar? <img src="http://mywebsite.com/cid/scale/100/mywebsite.com/Images/someImage.jpg" > - Also do you see any WARN flags in the CID logs - this should indicate if the URL is not constructed correctly. – Dylan .. Mark Saunders May 30 '17 at 12:05
  • There is no WARN flag in the CID log. also I am not getting the image with src="http://mywebsite.com/cid/mywebsite.com/Images‌​/someImage.jpg" – user2315 May 30 '17 at 12:18
0

In the SDL documentation on CID, its mentioned that we have to update the web.config as mentioned below

<location path="CUSTOM/PATH">
  <system.webServer>
     <handlers>
       <add name="ImageTransformerHandler" verb="*" path="CUSTOM/PATH/*" type="Tridion.Context.Image.Handler.ImageTransformerHandler" />
     </handlers>
  </system.webServer>
</location>

where /CUSTOM/PATH refers to the customized URL that you want the image transformer to run against. If you do not want to create a customized URL, omit the path attribute from the location element and set to the path attribute of the add element to *.

If we provide Path=”*” in web.config as shown below, then the log gets generated and nothing happens

<handlers>
 <add name="ImageTransformerHandler" verb="*" path=" *" type="Tridion.Context.Image.Handler.ImageTransformerHandler"  />
</handlers>

If we provide Path=” http://mywebsite/*” in web.config as shown below, then the log will not be generated but the folders structure (\cid\trim\100\source) get created automatically in mywebsite.com

<handlers>
 <add name="ImageTransformerHandler" verb="*" path=" http://mywebsite/*" type="Tridion.Context.Image.Handler.ImageTransformerHandler"  />
</handlers>

I am not clear on what exactly we have to provide in the PATH attribute.

  • This doesn't look like an answer but more an edit on the original question, can you please delete this answer and edit the question to keep the site clean and clear? – Bart Koopman Sep 29 '17 at 7:56

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.