CrumpledDog / Umbraco-AzureCDNToolkit

Makes it easy to fully utilise the Azure CDN with a Umbraco website
13 stars 14 forks source link

Image urls are wrong in RTE in Umbraco 7.6.+ #18

Open dawoe opened 5 years ago

dawoe commented 5 years ago

Hi @Jeavon

We just discovered an issue on 7.10.x site where images in the RTE don't get their link set up correctly

The image url looks like this : <img style="width: 500px; height:333.33333333333337px;" src="//media/2936/tamara-willems-600x400.png?width=500&amp;height=333.33333333333337" alt="" data-udi="umb://media/89b8f18cb19f450681eb882d0987724c">

Not the double // at the beginning.

I have had a peak at the code for Property Value Converter. This looks for data-id attribute. But that is not being used anymore in 7.6+ sites. There it is data-udi containing the udi for the media item.

For reference this is our full config :

<add key="AzureCDNToolkit:UseAzureCdnToolkit" value="false" />
    <add key="AzureCDNToolkit:Domain" value="http://mywebsitedomain.com" />
    <add key="AzureCDNToolkit:CdnUrl" value="https://mycdn.azureedge.net" />
    <add key="AzureCDNToolkit:CdnPackageVersion" value="0.0.1" />
    <add key="AzureCDNToolkit:AssetsContainer" value="assets" />
    <add key="AzureCDNToolkit:MediaContainer" value="media" />
    <add key="AzureCDNToolkit:SecurityModeEnabled" value="false" />
    <add key="AzureCDNToolkit:SecurityToken" value="" />

I wanted to make a PR for this. But that will break the minimum required Umbraco version.

Is that okay for you ?

Dave