Please see: https://github.com/kevinSuttle/html-meta-tags, thanks for the idea @dandv!
Copied from http://code.lancepollard.com/complete-list-of-html-meta-tags/
<Project xmlns='http://schemas.microsoft.com/developer/msbuild/2003' ToolsVersion="12.0"> | |
<PropertyGroup Condition="($(VersionCode)!='' or $(VersionName)!='' or $(FileVersion)!='')"> | |
<_PreResourceBuildTargets>_SetFileVersion</_PreResourceBuildTargets> | |
<CoreBuildDependsOn>$(_PreResourceBuildTargets);$(CoreBuildDependsOn)</CoreBuildDependsOn> | |
</PropertyGroup> | |
<UsingTask TaskName="__SetFileVersion" TaskFactory="CodeTaskFactory" AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v12.0.dll"> | |
<ParameterGroup> | |
<VerInfoKeys ParameterType="System.String" Required="true" /> | |
<VersionCode ParameterType="System.String" Required="false" /> | |
<VersionName ParameterType="System.String" Required="false" /> |
using Umbraco.Core; | |
using Umbraco.Core.Events; | |
using Umbraco.Core.IO; | |
using Umbraco.Core.Services; | |
namespace Startup | |
{ | |
public class MediaEventHandler : ApplicationEventHandler | |
{ | |
protected override void ApplicationStarted(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext) |
/// <summary> | |
/// Gets the media item by it's file path | |
/// </summary> | |
/// <remarks> | |
/// Example usage: Use in conjunction with HtmlAgilityPack or WYSIWYG.xslt to parse your RTE for Media Images, grab associated | |
/// properties from the Media node, and render them in your output (think alt tags, captions, etc). | |
/// TODO: support non "/media" directory, cleanup & further testing | |
/// </remarks> | |
/// <param name="mediaPath">Path to the uploaded file in the media directory</param> | |
/// <returns>Media node which contains the specified file</returns> |