We have an image with filename as "Tim%20Butler%20Trading.jpg". This image is linked as a component link in the "Image" field of the main component. In C# DLL we read this "Image" field and form image tag as follows:
"<img " + style + " src=\"" + imageID + "\" />"
where style is the attribute name if any and imageID is the tcm id of the multimedia component.
Output string is formed using image, title and some other field values from the component. This output is pushed into package to access it in dwt. The contentType of the output string passed to dwt is "HTML".
We are using DefaultFinishActions to publish images. This image is getting deployed on presenation server as Tim%20Butler%20Trading34-13565.jpg but not getting resolved on presentation side.
In page source image tag is formed as follows:
<img src="/images/Tim%2520Butler%2520Trading34-13565.jpg" class="img" />
We think that DWT is converting % in image file name to %25 when image is published.
Can someone let me know how to resolve this issue?
The problem is in %
sign. When template sees %
sign it is encoding it as %25
.
All you need to do is stop encoding it yourself. If your template will output Tim Butler Trading.jpg
, dreamweaver template will encode spaces as %20
and everyhting should work
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With