Error executing template "Designs/Mobler/_parsed/Clean_NoBreadcrumb.parsed.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at Mobler.Website.CustomCode.Frontend.V2.Helpers.Website.createCanonical() in D:\a\1\s\Mobler.Website\CustomCode\Frontend\V2\Helpers\WebsiteHelper.cs:line 88
   at CompiledRazorTemplates.Dynamic.RazorEngine_176690ab676f44979764759b5e2dd0cb.Execute() in D:\dynamicweb.net\Solutions\mobler.LIVE\Files\Templates\Designs\Mobler\_parsed\Clean_NoBreadcrumb.parsed.cshtml:line 85
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.<>c__DisplayClass16_0.<RunCompile>b__0(TextWriter writer)
   at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
   at Dynamicweb.Rendering.RazorTemplateRenderingProvider.Render(Template template)
   at Dynamicweb.Rendering.TemplateRenderingService.Render(Template template)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @using System.Web; 2 @using System.Text.RegularExpressions 3 @using Dynamicweb.Core.Helpers 4 @using Dynamicweb.Rendering.Translation 5 @using Newtonsoft.Json 6 @using NuGet 7 @using Mobler.Website.CustomCode.Models 8 @using Vite.Dw.Extensions 9 @using HttpUtility = System.Web.HttpUtility 10 @using Mobler.Website.CustomCode.Frontend.V2.Helpers 11 12 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 13 14 @{ 15 string CurrentEcomShopId = Dynamicweb.Frontend.PageView.Current().Area.EcomShopId; 16 string CurrentEcomLanguageId = Dynamicweb.Ecommerce.Common.Context.LanguageID; 17 string MainShopLink = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("MainShopLink"); 18 string shopname = Website.GetShopName(); 19 string shopnameEncoded = HttpUtility.UrlEncode(shopname); 20 var shopInfo = Website.ShopInfo(); 21 string globalAreaName = GetGlobalValue("Global:Area.Name"); 22 23 string culture = Dynamicweb.Frontend.PageView.Current().Area.Culture; 24 string designFolder = Dynamicweb.Frontend.PageView.Current().Area.Layout.Design.Name; 25 26 string logoSrc = ""; 27 string logoSrcMobile = ""; 28 29 if (shopname.ToLower() != "møblér" && shopname.ToLower() != "mobler" && shopname.ToLower() != "m%c3%b8bl%c3%a9r" && !string.IsNullOrEmpty(shopname)) 30 { 31 logoSrc = "/Files/Templates/Designs/Mobler/dist/logos/mobler-" + shopname.Replace(" ", "").ToLower() + ".svg"; 32 logoSrcMobile = "/Files/Templates/Designs/Mobler/dist/logos/mobler-" + shopname.Replace(" ", "").ToLower() + "-mobile.svg"; 33 } else { 34 logoSrc = "/Files/Templates/Designs/Mobler/dist/logos/mobler.svg"; 35 logoSrcMobile = "/Files/Templates/Designs/Mobler/dist/logos/mobler.svg"; 36 } 37 38 //this defines a shoppage 39 if (GetString("Item.SystemName") == "TextPage") 40 { 41 shopname = GetString("DwPageName_2"); 42 } 43 44 string imageName = shopname.Replace(" ", string.Empty) + "-owner.png"; 45 string localShopPage = Website.localshopPage(); 46 string FindDealerPage = GetString("Item.Area.FindDealerPage"); 47 string CartPage = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("CartPage"); 48 49 string SearchNoResults = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("NoResults"); 50 string SearchPagePageSize = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SearchPagePageSize") != "0" ? Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SearchPagePageSize") : "20"; 51 string InstantSearchSize = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("InstantsearchPageSize") != "0" ? Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("InstantsearchPageSize") : "10"; 52 53 string SearchResultPageId = ""; 54 if (Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SearchResultPage").Split('=').Length > 1) 55 { 56 SearchResultPageId = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SearchResultPage").Split('=')[1]; 57 } 58 string FooterLinkDestination = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("Link"); 59 int ShopPageId = GetInteger("Item.Area.ShopPageId"); 60 string SearchBarPlaceholder = Translate("SearchbarPlaceholderText", "S&oslash;g.."); 61 int GlobalNewsletterParagraphId = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetInt("GlobalNewsletterParagraphId"); 62 int CartCount = GetLoop("OrderLines").Count; 63 bool FirstShopWithSameName = true; 64 string SelectPlaceholder = Translate("ShopSelectPlaceholder", "Indtast by, postnummer eller adresse"); 65 string SelectNoResult = Translate("ShopSelectNoResult", "No such shop found"); 66 int ProductPage = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetInt("PrimaryProductPage"); 67 68 DateTime today = DateTime.Today; 69 string currentYear = today.ToString("yyyy"); 70 71 string BannerBackgroundColor = GetString("Item.Area.BannerBackgroundColor"); 72 string BannerTextColor = GetString("Item.Area.BannerTextColor"); 73 var TopBarNav = GetLoop("Item.Area.TopBarNavigation"); 74 var TopbarHeaderContent = GetLoop("Item.Area.TopbarHeaderContent"); 75 string TilbudBgColor = !String.IsNullOrEmpty(GetString("Item.Area.TilbudBackgroundColor.Value")) ? GetString("Item.Area.TilbudBackgroundColor.Value") : "#00AB5D"; 76 string TilbudTextColor = !String.IsNullOrEmpty(GetString("Item.Area.TilbudTextColor.Value")) ? GetString("Item.Area.TilbudTextColor.Value") : "#FFFFFF"; 77 string StrongPriceBgColor = !String.IsNullOrEmpty(GetString("Item.Area.St_rkPrisBackgroundColor.Value")) ? GetString("Item.Area.St_rkPrisBackgroundColor.Value") : "#9d4778"; 78 string StrongPriceTextColor = !String.IsNullOrEmpty(GetString("Item.Area.St_rkPrisTextColor.Value")) ? GetString("Item.Area.St_rkPrisTextColor.Value") : "#FFFFFF"; 79 var uniqueSellingPoints = GetLoop("Item.Area.UniqueSellingPoints"); 80 string CookieText = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("CookieText"); 81 string CookieReadMore = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("CookieReadMoreText"); 82 var TopLevelGroups = Dynamicweb.Ecommerce.Services.ProductGroups.GetToplevelGroups().Where(g => g.ShopId == CurrentEcomShopId && g.LanguageId == CurrentEcomLanguageId && g.NavigationShowInMenu).ToList(); 83 string CurrentUri = HttpContext.Current.Request.Url.PathAndQuery.ToString().Replace("/Default.aspx", "Default.aspx"); 84 string convertedUri = Dynamicweb.Frontend.SearchEngineFriendlyURLs.GetFriendlyUrl(CurrentUri); 85 string CanonicalUri = Website.createCanonical(); 86 string CanonicalDomain = "mobler.dk"; 87 if (Website.IsLocalWebshop()) 88 { 89 CanonicalDomain = System.Web.HttpContext.Current.Request.Url.Host; 90 } 91 string CanonicalURL = "https://" + CanonicalDomain + CanonicalUri; 92 string AvisLink = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("Avis"); 93 string FindShopSearchPlaceholder = Translate("HeaderNav.FindShopPlaceholder", "Indtast postnr., by eller adresse"); 94 string SetBannerEndpoint = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("GetCartJson"); 95 bool ShowTopBanner = Mobler.Website.CustomCode.Frontend.V2.Helpers.MessageBanner.ShowMessageBanner(); 96 bool EnableTopBarHeader = GetBoolean("Item.Area.EnableTopBarHeader.Value"); 97 bool EnableTopBarNavigation = GetBoolean("Item.Area.EnableTopBarBanner.Value") && ShowTopBanner; 98 99 bool EnableGoogleShoppingScript = GetBoolean("Item.Area.EnableGoogleShoppingScript.Value"); 100 string GoogleShoppingContentKey = GetString("Item.Area.GoogleShoppingContentKey.Value"); 101 102 bool EnableFacebookScript = GetBoolean("Item.Area.EnableFacebookScript.Value"); 103 string FacebookScriptContentKey = GetString("Item.Area.FacebookScriptContentKey.Value"); 104 string PinterestDomainVerifyContentKey = GetString("Item.Area.PinterestDomainVerifyContentKey.Value"); 105 106 bool IsCheckoutStep = false || HttpContext.Current.Request.RawUrl.Contains("checkout"); 107 bool isCheckoutFirstStep = false || HttpContext.Current.Request.RawUrl.Contains("indkoebskurv"); 108 } 109 110 <!doctype html> 111 <html lang="da" class="box-border overflow-x-hidden w-screen"> 112 113 @SnippetStart("LocalShopPage") 114 <a class="menu-item py-2 px-3 px-md-0" href="@localShopPage"> 115 <span>@Translate("MenuAboutUs.Text", "Om os")</span> 116 <div class="mobile-menu-arrow"> 117 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 118 </div> 119 </a> 120 @SnippetEnd("LocalShopPage") 121 122 @SnippetStart("MenuArrowSvg") 123 <div class="mobile-menu-arrow"> 124 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 125 </div> 126 @SnippetEnd("MenuArrowSvg") 127 128 @SnippetStart("MenuDownArrowSvg") 129 <div class="mobile-menu-down-arrow"> 130 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 131 </div> 132 @SnippetEnd("MenuDownArrowSvg") 133 134 @foreach (var TopLevelGroup in TopLevelGroups) 135 { 136 string snippetName = TopLevelGroup.Id; 137 if (snippetName.Contains("-")) 138 { 139 snippetName = snippetName.Split(new char[] { '-' })[1]; 140 } 141 142 @SnippetStart(snippetName) 143 foreach (var primaryGroup in TopLevelGroup.Subgroups.Where(pg => pg.NavigationShowInMenu)) 144 { 145 string primaryGroupUrl; 146 string menuLinkText = primaryGroup.Name; 147 string AlternativeLink = primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("alternativelink") != null ? "" + primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("alternativelink").Value : ""; 148 string AlternativeLinkText = primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("alternativelinktext") != null ? "" + primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("alternativelinktext").Value : ""; 149 if (!string.IsNullOrEmpty(AlternativeLinkText)) 150 { 151 menuLinkText = AlternativeLinkText; 152 } 153 154 if (!string.IsNullOrEmpty(AlternativeLink)) 155 { 156 primaryGroupUrl = AlternativeLink; 157 } 158 else 159 { 160 primaryGroupUrl = !string.IsNullOrEmpty(primaryGroup.ProductGroupFieldValues 161 .GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString()) ? 162 primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString() : 163 TopLevelGroup.Meta.PrimaryPage + "&GroupID=" + primaryGroup.Id; 164 } 165 166 // When using alternative link, to display a universe page, let's create an "All" link, for that category 167 string primaryGroupPage = ""; 168 if (!string.IsNullOrEmpty(AlternativeLink)) 169 { 170 primaryGroupPage = !string.IsNullOrEmpty(primaryGroup.ProductGroupFieldValues 171 .GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString()) ? 172 primaryGroup.ProductGroupFieldValues.GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString() : 173 TopLevelGroup.Meta.PrimaryPage + "&GroupID=" + primaryGroup.Id; 174 } 175 176 <div class="category"> 177 <div class="sub-menu-item has-drop category-header justify-between items-center w-full px-3 py-2 flex md:hidden"> 178 @primaryGroup.Name 179 <div class="mobile-menu-down-arrow"> 180 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 181 </div> 182 </div> 183 <div class="sub-drop"> 184 <a href="@(primaryGroupUrl)"> 185 <div class="sub-menu-item has-drop category-header link flex justify-between items-center w-full px-3 py-2 md:px-0"> 186 <div class="ml-3 ml-md-0"> 187 <div class="inline md:hidden">@Translate("Navigation.Mobile.GroupTitle", "Gå til:")</div> @menuLinkText 188 </div> 189 <div class="mobile-menu-arrow"> 190 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 191 </div> 192 </div> 193 </a> 194 @if (!string.IsNullOrEmpty(primaryGroupPage)) 195 { 196 <div> 197 <a class="px-3 py-2 flex justify-between items-center w-full ecom-link" href="@(primaryGroupPage)#@(CStrings.productListAnchorId)"> 198 <span class="ml-2 ml-md-0">@Translate("Navigation.Group.All", "Alle") @primaryGroup.Name.ToLower()</span> 199 <div class="mobile-menu-arrow"> 200 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 201 </div> 202 </a> 203 </div> 204 } 205 @foreach (var SubGroup in primaryGroup.Subgroups.Where(sg => sg.NavigationShowInMenu)) 206 { 207 string GroupLink = SubGroup.ProductGroupFieldValues.GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").HasValue && !String.IsNullOrEmpty(SubGroup.ProductGroupFieldValues.GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString()) ? SubGroup.ProductGroupFieldValues.GetProductGroupFieldValue("LinkToGroupsPrimaryPosition").Value.ToString() : "/" + TopLevelGroup.Meta.PrimaryPage + "&GroupID=" + SubGroup.Id; 208 <div> 209 <a class="px-3 py-2 flex justify-between items-center w-full ecom-link" href="@(GroupLink)#@(CStrings.productListAnchorId)"> 210 <span class="group-name">@SubGroup.Name</span> 211 <div class="mobile-menu-arrow"> 212 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M23.245 4l-11.245 14.374-11.219-14.374-.781.619 12 15.381 12-15.391-.755-.609z"></path></svg> 213 </div> 214 </a> 215 216 </div> 217 } 218 </div> 219 </div> 220 } 221 @SnippetEnd(snippetName) 222 } 223 224 <head> 225 <script> 226 // Temporary workaround for hiding the Cookiebot banner from Web Vitals scans 227 // https://support.cookiebot.com/hc/en-us/articles/360020501579-Google-Core-Web-Vitals-and-Cookiebot-CMP#h_01H05PZGDJ2TGTZBP5R1FC8EMH 228 window.addEventListener("CookiebotOnDialogInit", function() { 229 if (Cookiebot.getDomainUrlParam("CookiebotScan") === "true") 230 Cookiebot.setOutOfRegion(); 231 }); 232 </script> 233 <script id="Cookiebot" src="https://consent.cookiebot.com/uc.js" data-cbid="ec05aeab-ec7b-4d91-81fc-a8ebbcce1f2f" data-blockingmode="auto" type="text/javascript"></script> 234 <script data-cookieconsent="ignore"> 235 window.domGaTrackingEvents = []; 236 window.domFbqTrackingEvents = []; 237 238 window.dataLayer = window.dataLayer || []; 239 function gtag() { 240 dataLayer.push(arguments); 241 } 242 gtag("consent", "default", { 243 ad_storage: "denied", 244 analytics_storage: "denied", 245 functionality_storage: "denied", 246 personalization_storage: "denied", 247 security_storage: "granted", 248 wait_for_update: 500, 249 }); 250 gtag("set", "ads_data_redaction", true); 251 gtag("set", "url_passthrough", true); 252 </script> 253 @*GTM*@ 254 <script> 255 var ecomm_pagetype = "other"; 256 var ecomm_totalvalue = 0; 257 var ecomm_prodid = ""; 258 </script> 259 @RenderSnippet("DataLayerOverwrites") 260 261 @RenderSnippet("DataLayerOverwriteReceipt") 262 263 <!-- Google Tag Manager --> 264 <script data-cookieconsent="ignore">!function () { "use strict"; function e(e) { return function (e) { for (var t = 0, r = document.cookie.split(";"); t < r.length; t++) { var n = r[t].split("="); if (n[0].trim() === e) return n[1] } }(e) } function t(e) { return localStorage.getItem(e) } function r(e) { return window[e] } function n(e, t) { var r = document.querySelector(e); return t ? null == r ? void 0 : r.getAttribute(t) : null == r ? void 0 : r.textContent } !function (o, i, a, c, u, l, s, v, d, f, g) { var E, I, m, T; try { I = d && (m = navigator.userAgent, (T = new RegExp("Version/([0-9._]+)(.*Mobile)?.*Safari.*").exec(m)) && parseFloat(T[1]) >= 16.4) ? function (o, i, a) { void 0 === i && (i = ""); var c = { cookie: e, localStorage: t, jsVariable: r, cssSelector: n }, u = Array.isArray(i) ? i : [i]; if (o && c[o]) for (var l = c[o], s = 0, v = u; s < v.length; s++) { var d = v[s], f = a ? l(d, a) : l(d); if (f) return f } else console.warn("invalid uid source", o) }(d, "user_id", "") : void 0 } catch (e) { console.error(e) } var _ = o; _[c] = _[c] || [], _[c].push({ "gtm.start": (new Date).getTime(), event: "gtm.js" }); var p = i.getElementsByTagName(a)[0], A = I ? "&bi=" + encodeURIComponent(I) : "", N = i.createElement(a), D = I ? "kp" + v : v, R = !I && s ? s : "https://gtm.mobler.dk"; N.async = !0, N.src = R + "/" + D + ".js?id=GTM-PN9ZSS" + A, null === (E = p.parentNode) || void 0 === E || E.insertBefore(N, p) }(window, document, "script", "dataLayer", 0, 0, "", "rcuxkqbl", "cookie") }();</script> 265 <!-- End Google Tag Manager --> 266 <!-- Required meta tags --> 267 <meta charset="utf-8"> 268 <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> 269 270 @if (string.IsNullOrEmpty(Dynamicweb.Context.Current.Request["productid"])) 271 { 272 273 274 <title>@GetValue("Title")</title> 275 @GetValue("MetaTags") 276 @GetValue("CopyRightNotice") 277 278 } 279 else 280 { 281 @RenderSnippet("ProductDetailsMeta") 282 } 283 284 @if ((Mobler.Website.CustomCode.Frontend.Helper.IsLocalWebshop() && !System.Web.HttpContext.Current.Request.RawUrl.ToLower().EndsWith("/om-os")) || System.Web.HttpContext.Current.Request.Url.Host.ToLower().Contains("1stweb") || System.Web.HttpContext.Current.Request.Url.AbsoluteUri.ToLower().Contains("groupid=pim-")) 285 { 286 <meta name="robots" content="noindex"> 287 } 288 289 @if (!Mobler.Website.CustomCode.Frontend.Helper.IsLocalWebshop()) 290 { 291 <link rel="canonical" href="@CanonicalURL"> 292 } 293 <meta property="og:url" content="@CanonicalURL"> 294 <meta property="og:title" content="@GetValue(" title")"=""> 295 296 <link rel="shortcut icon" type="image/ico" href="/Files/Templates/Designs/Mobler2016/images/icons/favicon.ico"> 297 298 @if (GetString("Item.SystemName") == "BlogPost") 299 { 300 string imageMasterPage = GetString("Item.Billede.Value"); 301 string TeaserText = Regex.Replace(GetString("Item.TeaserTekst"), "<.*?>", String.Empty); 302 <meta property="og:type" content="article"> 303 <meta property="og:description" content="@TeaserText"> 304 <meta property="og:image" content="@imageMasterPage"> 305 } 306 else if (GetString("Item.SystemName") == "Brand") 307 { 308 string imageMasterPage = GetString("Item.Logo.Value"); 309 string TeaserText = GetString("Item.Navn"); 310 <meta property="og:type" content="article"> 311 <meta property="og:description" content="@TeaserText"> 312 <meta property="og:image" content="@imageMasterPage"> 313 } 314 else if (System.Web.HttpContext.Current.Items["OverrideOgTags"] != null) 315 { 316 @RenderSnippet("OgTags") 317 } 318 else 319 { 320 <meta property="og:type" content="business.business"> 321 <meta property="og:description" content="@GetString(" meta.description")"=""> 322 <meta property="og:image" content="https://mobler.dk/Files/Templates/Designs/Mobler2018/dist/logos/mobler.svg"> 323 } 324 325 326 @if (EnableGoogleShoppingScript && !string.IsNullOrEmpty(GoogleShoppingContentKey)) 327 { 328 <meta name="google-site-verification" content="@GoogleShoppingContentKey"> 329 } 330 331 @if (EnableFacebookScript && !string.IsNullOrEmpty(FacebookScriptContentKey)) 332 { 333 <meta name="facebook-domain-verification" content="@FacebookScriptContentKey"> 334 } 335 336 @if (EnableFacebookScript && !string.IsNullOrEmpty(PinterestDomainVerifyContentKey)) 337 { 338 <meta name="p:domain_verify" content="@PinterestDomainVerifyContentKey"> 339 } 340 341 @Pageview.AddViteStyles() 342 343 <link rel="preconnect" href="https://content.cylindo.com" crossorigin=""> 344 345 346 @GetValue("Stylesheets") 347 @GetValue("Javascripts") 348 </head> 349 @{ 350 bool isBlackFriday = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetBoolean("BlackFridayTheme"); 351 string blackFridayThemeClass = isBlackFriday ? "theme--black-friday" : ""; 352 } 353 <body class="@blackFridayThemeClass" data-bind="viewModel: 'MasterViewModel', Cookies" data-currentshopislocalwebshop="@Mobler.Website.CustomCode.Frontend.Helper.IsLocalWebshop()" data-mainshoplink="@MainShopLink" data-culture="@culture" data-design="@designFolder"> 354 355 <!-- Google Tag Manager (noscript) --> 356 <noscript><iframe src="https://gtm.mobler.dk/ns.html?id=GTM-PN9ZSS" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript> 357 <!-- End Google Tag Manager (noscript) --> 358 359 <div data-bind="viewModel: 'HeaderViewModel'"> 360 <div class="menu-open-overlay" data-bind="css: { active: MenuOpen }, click: ToggleMenu"></div> 361 <header class="js-header"> 362 <topnavigation></topnavigation> 363 364 @if (EnableTopBarNavigation && !IsCheckoutStep && TopBarNav != null) 365 { 366 dynamic NotificationData = new 367 { 368 bannerStyle = new 369 { 370 backgroundColor = BannerBackgroundColor, 371 textColor = BannerTextColor 372 }, 373 bannerContent = TopBarNav.Select(item => new 374 { 375 link = item.GetString("Item.Area.TopBarNavigation.NavItemLink"), 376 text = item.GetString("Item.Area.TopBarNavigation.NavItemText") 377 }).ToList() 378 }; 379 object NotificationDataJson = HttpUtility.HtmlAttributeEncode(Newtonsoft.Json.JsonConvert.SerializeObject(NotificationData)); 380 <script>//console.log("%cNotificationDataJson", "color:white;background:rebeccapurple;padding:5px;", @Newtonsoft.Json.JsonConvert.SerializeObject(NotificationData, new Newtonsoft.Json.JsonSerializerSettings {ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Ignore, PreserveReferencesHandling = Newtonsoft.Json.PreserveReferencesHandling.Objects}));</script> 381 382 <notificationelement data-theme="info" data-content="@NotificationDataJson"></notificationelement> 383 @*<div class="container-fluid js-top-banner topbar-nav"> 384 385 <div class="text-center" style="background-color:@BannerBackgroundColor;"> 386 <div class="flex justify-center items- py-1"> 387 <ul class="list-none"> 388 @foreach (var navItem in TopBarNav) 389 { 390 string ItemLink = navItem.GetString("Item.Area.TopBarNavigation.NavItemLink"); 391 string ItemText = navItem.GetString("Item.Area.TopBarNavigation.NavItemText"); 392 <li> 393 <a class="nav-link p-1 rte-content" href='@ItemLink' style="color:@BannerTextColor;"> 394 @ItemText 395 </a> 396 </li> 397 } 398 </ul> 399 <div class="ml-2"> 400 <a href="#" data-bind="topBanner: { target: '.js-top-banner', endpoint: '@SetBannerEndpoint' }"> 401 <i class="fa-solid fa-xmark" style="color:@BannerTextColor;"></i> 402 </a> 403 </div> 404 </div> 405 </div> 406 </div>*@ 407 } 408 <div class="container-fluid lg:border-b lg:border-b-grey"> 409 <div class="container"> 410 @{ 411 var GridRowsClass = IsCheckoutStep ? "grid-rows-1" : "grid-rows-2"; 412 string completedOrderParameter = System.Web.HttpContext.Current.Request.QueryString["CompletedOrderId"]; 413 } 414 <div class="grid items-center gap-x-2 gap-y-4 xl:gap-8 pt-4 lg:py-4 @GridRowsClass lg:grid-rows-1 grid-cols-4 lg:grid-cols-3 auto-rows-max"> 415 @if (IsCheckoutStep) 416 { 417 @* If we are on the receipt page *@ 418 if (string.IsNullOrEmpty(completedOrderParameter)) 419 { 420 <div onclick="window.history.back()" class="w-fit col-span-2 lg:col-span-1 px-6 py-2 rounded-full bg-white text-black border-2 border-black hover:text-black hover:border-grey-dark hover:cursor-pointer active:border-grey-dark active:bg-grey"> 421 <span> 422 <i class="fa-solid fa-arrow-left mr-1"></i> Tilbage 423 </span> 424 </div> 425 } 426 427 428 <div class="flex lg:items-center lg:justify-center col-span-2 col-start-3 lg:col-span-1 lg:col-start-2"> 429 <div class="w-full"> 430 <a href="/" class="flex flex-col md:items-center"> 431 <img width="400" height="46" class="max-h-[50px] hidden md:inline-block" src="@logoSrc" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 432 <img width="400" height="46" class="max-h-[50px] w-full object-contain object-left inline md:hidden" src="@logoSrcMobile" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 433 @if (shopname.ToLower() != "møblér" && shopname.ToLower() != "mobler" && shopname.ToLower() != "m%c3%b8bl%c3%a9r" && !string.IsNullOrEmpty(shopname)) 434 { 435 <small class="text-xs text-grey-dark md:text-center">@Translate("LogoServiceText", "Ordren serviceres af Møbler.dk")</small> 436 } 437 </a> 438 </div> 439 </div> 440 } 441 442 @if (!IsCheckoutStep) 443 { 444 <div class="flex lg:items-center lg:justify-center col-span-2 lg:col-span-1 lg:col-start-2"> 445 <div class="w-full"> 446 <a href="/" class="flex flex-col md:items-center"> 447 <img width="400" height="46" class="max-h-[50px] hidden md:inline-block" src="@logoSrc" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 448 <img width="400" height="46" class="max-h-[50px] w-full object-contain object-left inline md:hidden" src="@logoSrcMobile" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 449 @if (shopname.ToLower() != "møblér" && shopname.ToLower() != "mobler" && shopname.ToLower() != "m%c3%b8bl%c3%a9r" && !string.IsNullOrEmpty(shopname)) 450 { 451 <small class="text-xs text-grey-dark md:text-center">@Translate("LogoServiceText", "Ordren serviceres af Møbler.dk")</small> 452 } 453 </a> 454 </div> 455 </div> 456 457 <actionbar class="flex items-center col-span-2 lg:col-span-1"></actionbar> 458 459 <div class="flex col-span-full gap-x-2 lg:col-span-1 lg:col-start-1 lg:row-start-1"> 460 <div class="flex flex-col justify-center items-center w-12 lg:hidden" id="mobileMenuIcon" data-bind="click: ToggleMenu"> 461 <i class="fa-light fa-bars fa-xl"></i> 462 <p class="mt-1 text-xs md:text-sm">@Translate("MobileMenu.Text", "Menu")</p> 463 </div> 464 465 <searchbar id="js-search-bar" class="w-full" data-no-results="@SearchNoResults"></searchbar> 466 </div> 467 } 468 else 469 { 470 <div class="flex items-center justify-end col-span-2 lg:col-span-1"> 471 <shopwidget></shopwidget> 472 </div> 473 } 474 </div> 475 </div> 476 </div> 477 @if (!IsCheckoutStep) 478 { 479 <div class="container py-4"> 480 <div class="relative"> 481 <nav class="menu mt-md-3 mt-lg-4" data-bind="css: { open: MenuOpen }, menuToggler: { menuItemSelector: '.menu-item.has-drop', subMenuItemSelector: '.sub-menu-item.has-drop', isMenuOpenObs: MenuOpen, productsArray: Products, searchError: SearchError }"> 482 <div class="mobile-navigation-top p-4 flex justify-content-between md:hidden js-mobile-navigation"> 483 <div class="w-full"> 484 <a href="/" class="flex flex-col md:items-center"> 485 <img width="400" height="46" class="max-h-[46px] hidden md:inline-block" src="@logoSrc" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 486 <img width="400" height="46" class="max-h-[46px] w-full object-contain object-left inline md:hidden" src="@logoSrcMobile" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 487 @if (shopname.ToLower() != "møblér") 488 { 489 <small class="text-xs text-grey-dark text-center hidden md:block">@Translate("LogoServiceText", "Ordren serviceres af Møbler.dk")</small> 490 } 491 </a> 492 </div> 493 <div class="mobile-menu-closer px-3 flex flex-col items-center justify-center" data-bind="click: ToggleMenu"> 494 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill-rule="evenodd" clip-rule="evenodd"><path d="M12 11.293l10.293-10.293.707.707-10.293 10.293 10.293 10.293-.707.707-10.293-10.293-10.293 10.293-.707-.707 10.293-10.293-10.293-10.293.707-.707 10.293 10.293z"></path></svg> 495 <p class="mb-0">@Translate("Close", "Luk")</p> 496 </div> 497 </div> 498 <div class="hidden md:block z-30"> 499 <div class="menu-closer pointer"> 500 <button type="button" class="justify-self-end px-3 text-base hover:underline" data-bind="click: ToggleMenu"> 501 <span class="mr-2">Luk</span> 502 <i class="fa-light fa-close"></i> 503 </button> 504 </div> 505 </div> 506 <div class="flex flex-wrap md:gap-x-6 w-full justify-start"> 507 @RenderNavigation(new 508 { 509 ExpandMode = "All", 510 Template = "navigation.xslt", 511 TilbudTextColor = "color: " + TilbudTextColor + ";", 512 TilbudBgColor = "background-color: " + TilbudBgColor + ";", 513 StrongPriceBg = "background-color: " + StrongPriceBgColor + ";", 514 StrongPriceTextColor = "color: " + StrongPriceTextColor + ";" 515 }) 516 </div> 517 </nav> 518 </div> 519 </div> 520 } 521 </header> 522 <localshopmodal data-show="false" data-text="@GetString(" item.area.localwebshoptext")"="" data-shop-name="@shopnameEncoded" data-is-local-shop="@Mobler.Website.CustomCode.Frontend.Helper.IsLocalWebshop().ToString().ToLower()"></localshopmodal> 523 </div> 524 525 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 526 527 528 <div id="content1">@GetValue("DwContent(content1)")</div> 529 530 531 @if (!IsCheckoutStep) 532 { 533 if (!isCheckoutFirstStep) 534 { 535 var brandsLoop = @GetLoop("Item.Page.Brand_Icon.Value"); 536 <!-- TODO: (Out of scope) Clean this up so we don't repeat --> 537 <section class="container py-8"> 538 <div class="grid grid-cols-3 md:grid-cols-6 gap-4"> 539 @if (brandsLoop.Count <= 0) 540 { 541 foreach (var item in GetLoop("Item.Area.Featured_Brands")) 542 { 543 string Link = item.GetString("Item.Area.Featured_Brands.Brand.Value"); 544 var Brand = Firstweb.Custom.CustomCode.Frontend.Helpers.Brands.GetBrand(Link); 545 546 if (!String.IsNullOrEmpty(Brand.Name)) 547 { 548 <a href="@Brand.Link"> 549 <img width="900" height="400" class="img-fit-contain-x" src="/Admin/Public/GetImage.ashx?Image=@Brand.Logo&Format=webP&Quality=90&Height=400" alt="@Brand.Name"> 550 </a> 551 } 552 } 553 } 554 else 555 { 556 foreach (var item in brandsLoop) 557 { 558 string image = item.GetString("Item.Page.Brand_Icon.Value.Image.Value"); 559 string link = item.GetString("Item.Page.Brand_Icon.Value.LinkDestination.Value"); 560 561 if (!String.IsNullOrEmpty(image)) 562 { 563 <a href="@link"> 564 <img width="900" height="400" class="img-fluid" src="/Admin/Public/GetImage.ashx?Image=@image&Format=webP&Quality=90&Height=400" alt=""> 565 </a> 566 } 567 } 568 } 569 </div> 570 </section> 571 } 572 573 <section class="bg-beige pt-14 lg:pt-28"> 574 <div class="container flex flex-wrap"> 575 <div class="w-full md:w-3/4 lg:w-1/2 flex flex-col md:items-start gap-y-4"> 576 <a href="/" class="flex flex-col md:items-center"> 577 <img width="400" height="46" class="max-h-[46px] hidden md:inline-block" src="@logoSrc" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 578 <img width="400" height="46" class="max-h-[46px] w-full object-contain object-left inline md:hidden" src="@logoSrcMobile" alt='@Translate("LogoAltText", "Møblér: Alt indenfor møbler og boligindretning")'> 579 @if (shopname.ToLower() != "møblér") 580 { 581 <small class="text-xs text-grey-dark text-center hidden md:block">@Translate("LogoServiceText", "Ordren serviceres af Møbler.dk")</small> 582 } 583 </a> 584 585 <!-- TODO: This has not been tested and styled --> 586 @if (shopnameEncoded == "M%c3%b8bl%c3%a9r") 587 { 588 <div> 589 <p class="mb-0 font-bold">@GetString("Item.Area.Header")</p> 590 <p> 591 @GetString("Item.Area.About") 592 </p> 593 <a href="@FooterLinkDestination"><u>@Translate("FooterAboutReadMore", "L&aelig;s mere om M&oslash;blér k&aelig;den her")</u></a> 594 </div> 595 } 596 else 597 { 598 if (GetString("Item.SystemName") == "TextPage") 599 { 600 string CurrentAboutUsShopName = GetString("DwPageName_2"); 601 shopInfo = Website.ShopInfo(CurrentAboutUsShopName); 602 shopname = CurrentAboutUsShopName; 603 } 604 605 <div class="flex flex-wrap gap-y-4 w-full"> 606 <div class="w-full md:w-1/2"> 607 <ul class="list-none"> 608 <li class="mb-2"><strong>@shopInfo.ShopName</strong></li> 609 <li>@shopInfo.Address</li> 610 <li>@shopInfo.PostalAndCity</li> 611 <li> 612 <a href="@localShopPage" class="underline text-black">@Translate("ShowOnMap", "Vis p&#229; kort")</a> 613 </li> 614 615 @if (!String.IsNullOrEmpty(shopInfo.Address1)) 616 { 617 <li>@shopInfo.Address1, @shopInfo.PostalAndCity1</li> 618 } 619 @if (!String.IsNullOrEmpty(shopInfo.Address2)) 620 { 621 <li>@shopInfo.Address2, @shopInfo.PostalAndCity2</li> 622 } 623 <li class="mt-4">@shopInfo.Phone</li> 624 <li> 625 <a href="mailto:@shopInfo.Email" class="underline text-black">@shopInfo.Email</a> 626 </li> 627 </ul> 628 </div> 629 630 <div class="w-full md:w-1/2"> 631 @if (shopInfo.ShopInformationList.Count > 0 || shopInfo.OpeningHours != null) 632 { 633 <p class="mb-2"><strong>@Translate("openinghours", "&#197;bningstider")</strong></p> 634 } 635 @if (shopInfo.ShopInformationList.Count > 0) 636 { 637 foreach (var row in shopInfo.ShopInformationList) 638 { 639 var rowClass = !string.IsNullOrEmpty(row.columnTwo) ? "basis-1/2" : ""; 640 <div class="flex gap-x-2"> 641 <div class="@rowClass"> 642 @row.columnOne 643 </div> 644 @if (!string.IsNullOrEmpty(row.columnTwo)) 645 { 646 <div>@row.columnTwo</div> 647 } 648 </div> 649 } 650 } 651 else if (shopInfo.OpeningHours != null) 652 { 653 <div class="flex flex-col justify-content items-center gap-2 md:items-start">@shopInfo.OpeningHours</div> 654 } 655 </div> 656 657 </div> 658 } 659 <ul class="list-none flex gap-2 mb-8"> 660 @foreach (var Some in GetLoop("Item.Area.SocialMediaIcons")) 661 { 662 string Link = Some.GetString("Item.Area.SocialMediaIcons.Link"); 663 string Icon = Some.GetString("Item.Area.SocialMediaIcons.Icon.Value"); 664 <li> 665 <a href="@Link" target="_blank" class="text-black text-2xl hover:text-grey-dark"> 666 <img width="37" height="37" src="/Admin/Public/GetImage.ashx?Image=@Icon&Format=webP&Quality=90&Height=40" alt="social icon"> 667 </a> 668 </li> 669 } 670 671 @foreach (var Some in GetLoop("Item.Area.SocialMediaFontawesomeIcons")) 672 { 673 string Link = Some.GetString("Item.Area.SocialMediaFontawesomeIcons.Link"); 674 string Icon = Some.GetString("Item.Area.SocialMediaFontawesomeIcons.FontawesomeClass"); 675 <li> 676 <a href="@Link" target="_blank" class="text-black text-3xl hover:text-grey-dark"> 677 <i class="@Icon"></i> 678 </a> 679 </li> 680 } 681 </ul> 682 </div> 683 <div class="hidden lg:flex justify-center items-end w-full lg:w-2/4"> 684 @{ 685 string footerStaffImagePath = String.Format("/Files/Images/Owners/Large/{0}.png", shopname); 686 string footerStaffGetImage = ""; 687 if (!String.IsNullOrEmpty(footerStaffImagePath)) 688 { 689 footerStaffGetImage = "/Admin/Public/GetImage.ashx?Image=" + footerStaffImagePath + "&Format=webP&Quality=90&width=640&height=300"; 690 } 691 } 692 <img width="640" height="300" class="img-fit-contain-x" src="@footerStaffGetImage" alt="@shopname"> 693 </div> 694 </div> 695 </section> 696 697 <section class="bg-beige-dark py-10"> 698 <div class="container"> 699 <div class="flex flex-wrap xl:flex-nowrap xl:flex-row gap-4 "> 700 <div class="w-full grid md:grid-cols-3 xl:grid-cols-6 gap-y-4 *:list-none *:text-center *:md:text-left *:text-sm *:leading-8"> 701 <ul class="list-none col-span-3 md:col-span-1"> 702 <strong>@GetString("Item.Area.Footer_Column_1_Header")</strong> 703 @foreach (var Link in GetLoop("Item.Area.Footer_Column_1_Links")) 704 { 705 string LinkText = Link.GetString("Item.Area.Footer_Column_1_Links.LinkText"); 706 string LinkDestination = "/Default.aspx?id=" + Link.GetString("Item.Area.Footer_Column_1_Links.Link"); 707 <li> 708 <a href="@LinkDestination" class="text-black hover:underline hover:text-black">@LinkText</a> 709 </li> 710 } 711 </ul> 712 <ul class="list-none col-span-3 md:col-span-1"> 713 <strong>@GetString("Item.Area.Footer_Column_2_Header")</strong> 714 @foreach (var Link in GetLoop("Item.Area.Footer_Column_2_Links")) 715 { 716 string LinkText = Link.GetString("Item.Area.Footer_Column_2_Links.LinkText"); 717 string LinkDestination = "/Default.aspx?id=" + Link.GetString("Item.Area.Footer_Column_2_Links.Link"); 718 <li> 719 <a href="@LinkDestination" class="text-sm text-black">@LinkText</a> 720 </li> 721 } 722 </ul> 723 <ul class="list-none col-span-3 md:col-span-1"> 724 <strong>@GetString("Item.Area.Footer_Column_3_Header")</strong> 725 @foreach (var Link in GetLoop("Item.Area.Footer_Column_3_Links")) 726 { 727 string LinkText = Link.GetString("Item.Area.Footer_Column_3_Links.LinkText"); 728 string LinkDestination = "/Default.aspx?id=" + Link.GetString("Item.Area.Footer_Column_3_Links.Link"); 729 <li> 730 <a href="@LinkDestination" class="text-sm text-black">@LinkText</a> 731 </li> 732 } 733 </ul> 734 735 <div class="col-span-3"> 736 <strong>@Translate("Co3.Newsletter.Headline.Text", "Møblérs nyhedsbrev")</strong> 737 <newsletter></newsletter> 738 </div> 739 </div> 740 </div> 741 </div> 742 </section> 743 744 <div class="py-4 bg-white"> 745 <div class="container flex flex-col md:flex-row gap-y-4"> 746 <div class="w-full xl:w-1/2 flex justify-center items-center md:justify-start text-xs"> 747 © @currentYear @Translate("Copyright", "Møblér. All Rights Reserved.") 748 </div> 749 <div class="w-full xl:w-1/2 flex items-center md:justify-end"> 750 <a href='@Translate("PersondataLink", "link")' class="text-xs underline text-black mr-2">@Translate("PersondataText", "Persondatapolitik")</a> 751 <paymentmethodlogos data-all-payments="true"></paymentmethodlogos> 752 </div> 753 754 </div> 755 </div> 756 } 757 758 <script type="module" src="https://viewer-cdn.cylindo.com/v1/index.mjs" defer=""></script> 759 760 @Pageview.AddViteScript() 761 </body> 762 </html> 763