public override void Process( TagHelperContext context, TagHelperOutput output) { var value = TagValueUtility.GetContent( Value, SeoHelper.LinkCanonical); var linkCanonical = AbsoluteUrlUtility.Resolve( _urlHelper, value, SeoHelper.SiteUrl); if (string.IsNullOrWhiteSpace(linkCanonical)) { output.SuppressOutput(); return; } output.TagName = "link"; output.TagMode = TagMode.SelfClosing; output.Attributes.Clear(); output.Attributes.SetAttribute("rel", "canonical"); output.Attributes.SetAttribute("href", linkCanonical); }
public override void Process( TagHelperContext context, TagHelperOutput output) { var content = TagValueUtility.GetContent( Value, SeoHelper.OgImage); output.ProcessOpenGraph(OgMetaName.Image, content); }
public override void Process( TagHelperContext context, TagHelperOutput output) { var content = TagValueUtility.GetContent( Value, SeoHelper.MetaKeywords); output.ProcessMeta(MetaName.Keywords, content); }
public override void Process( TagHelperContext context, TagHelperOutput output) { var content = TagValueUtility.GetContent( Value, SeoHelper.MetaDescription); output.ProcessMeta(MetaName.Description, content); }
public override void Process( TagHelperContext context, TagHelperOutput output) { if (Follow != null || Index != null) { SeoHelper.SetMetaRobots(Index ?? true, Follow ?? true); } var content = TagValueUtility.GetContent( Value, SeoHelper.MetaRobots); output.ProcessMeta(MetaName.Robots, content); }
public override void Process( TagHelperContext context, TagHelperOutput output) { var value = TagValueUtility.GetContent( Value, SeoHelper.OgUrl, SeoHelper.LinkCanonical); var linkCanonical = AbsoluteUrlUtility.Resolve( _urlHelper, value, SeoHelper.SiteUrl); output.ProcessOpenGraph(OgMetaName.Url, linkCanonical); }