The Logging plugin allows the Image Resizer to perform logging (to disk, SQL, e-mail, whatever you configure).
It is a wrapper for NLog, and as such, requires NLog.dll
Install-Package ImageResizer.Plugins.Logging in the NuGet package manager, or:
- Add ImageResizer.Plugins.Logging.dll to your project. NLog.dll is also needed, but doesn't have to be referenced directly - it should be automatically copied if you are using Visual Studio. If not, copy it to the /bin folder as well
<add name="Logging" />inside
NuGet or not, you'll need to manually add a configuration section for NLog and configure logging rules & targets:
Currently, detailed logging has only been implemented for the DiskCache plugin. Set
logging=true on the
<diskcache /> element to enable it.
This plugin (Logging plugin (v3.1+)) is part of the Essential edition
Where is the plugins section?
<plugins> section is located in Web.config, and is nested inside the
<resizer> element, which is nested inside
<configuration>. For examples, see this sample Web.config file.
Where can I find the dll?
We prefer that you install via NuGet, but you can also find the plugin DLL files in the /dlls/release folder of your download.
How do I typically install a plugin via Web.Config?
- In Visual Studio, right click on your project and choose "Add reference". Browse to the plugin DLL and click "OK".
- In the <plugins> section of Web.config, insert <add name="PluginName" />
- Look at the plugin documentation to see what configuration options (if any) are available.