From bb1415f5dc1f81fb633f7a96e028dcaff5ef6fb0 Mon Sep 17 00:00:00 2001 From: Nick Date: Fri, 20 Jan 2023 09:27:42 +0900 Subject: [PATCH 1/2] Fixed xcopy not working Would not work if the path has a space. --- MetaMomentum.UmbracoV10/MetaMomentum.UmbracoV10.csproj | 2 +- MetaMomentum.UmbracoV8/MetaMomentum.UmbracoV8.csproj | 4 ++-- MetaMomentum.UmbracoV9/MetaMomentum.UmbracoV9.csproj | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/MetaMomentum.UmbracoV10/MetaMomentum.UmbracoV10.csproj b/MetaMomentum.UmbracoV10/MetaMomentum.UmbracoV10.csproj index f6002fe..6e5dd58 100644 --- a/MetaMomentum.UmbracoV10/MetaMomentum.UmbracoV10.csproj +++ b/MetaMomentum.UmbracoV10/MetaMomentum.UmbracoV10.csproj @@ -44,6 +44,6 @@ false - + diff --git a/MetaMomentum.UmbracoV8/MetaMomentum.UmbracoV8.csproj b/MetaMomentum.UmbracoV8/MetaMomentum.UmbracoV8.csproj index 281777b..74a4f58 100644 --- a/MetaMomentum.UmbracoV8/MetaMomentum.UmbracoV8.csproj +++ b/MetaMomentum.UmbracoV8/MetaMomentum.UmbracoV8.csproj @@ -375,8 +375,8 @@ - xcopy $(SolutionDir)MetaMomentum\App_Plugins\MetaMomentum\*.* $(ProjectDir)App_Plugins\MetaMomentum\ /S /E /Y -xcopy $(SolutionDir)MetaMomentum\Views\Partials\MetaMomentum\*.* $(ProjectDir)Views\Partials\MetaMomentum\ /S /E /Y + xcopy "$(SolutionDir)MetaMomentum\App_Plugins\MetaMomentum\*.*" "$(ProjectDir)App_Plugins\MetaMomentum\" /S /E /Y +xcopy "$(SolutionDir)MetaMomentum\Views\Partials\MetaMomentum\*.*" "$(ProjectDir)Views\Partials\MetaMomentum\" /S /E /Y {{(showEditSocial)? "Hide Preview" : "Edit Preview"}} + @@ -120,18 +121,21 @@ - + Edit -
+ Fallback Image Field + Site Fallback Image +
{{searchHost}} @@ -150,6 +154,8 @@ +
@@ -172,6 +178,8 @@ +
diff --git a/MetaMomentum/Views/Partials/MetaMomentum/RenderMetaTags.cshtml b/MetaMomentum/Views/Partials/MetaMomentum/RenderMetaTags.cshtml index cedcda3..8c07ca1 100644 --- a/MetaMomentum/Views/Partials/MetaMomentum/RenderMetaTags.cshtml +++ b/MetaMomentum/Views/Partials/MetaMomentum/RenderMetaTags.cshtml @@ -28,9 +28,18 @@ @*Twitter Card ratio is 2:1 https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/summary-card-with-large-image *@ @**@ - - + +} +else if (!string.IsNullOrEmpty(Model.FallbackImageUrl)) +{ + @* Meta(FB) require images at least 1200x630 https://developers.facebook.com/docs/sharing/webmasters/images/ *@ + + + + @*Twitter Card ratio is 2:1 https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/summary-card-with-large-image *@ + @**@ + } @if (Model.NoIndex)