Domanda

I am making a desperate attempt at using the ImageGen tool with the Umbraco:Image control...

The "documentation" (hack cough) for the control is here: http://our.umbraco.org/Documentation/Reference/Templating/Masterpages/umbracoimage

At the bottom it glibly mentions how you can use a custom provider for ImageGen... then fails to link to documentation for ANYTHING related to this. I did manage to find some sample code link from ImageGen. Sadly, that sample also fails to explain how to actually get this to work in your Umbraco setup. One big question remains:

How do I register or configure this bit of code so that the example usage actually works? I know there is more to it than just adding Provider="imageGen" in the tag. I cannot find any documentation for this interface.

È stato utile?

Soluzione

You need to write your own class which inherits from the IImageUrlProvider interface. You could take a look at the one in the Core Umbraco to see an example of how to implement one of your own. Once you have your own I don't believe you need to do anything further to wire it up you just follow the example in the docs to specify which provider to use on your umbraco:Image control.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top