Error executing template "Designs/Catago/_parsed/fullwidth.parsed.cshtml"
System.IO.IOException: The process cannot access the file 'D:\dynamicweb.net\Solutions\eldorado.LIVE\Files\Templates\Designs\Dwsimple\css\DWGlobalStyles.min.css' because it is being used by another process.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.StreamWriter.CreateFile(String path, Boolean append, Boolean checkHost)
   at System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize, Boolean checkHost)
   at System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding)
   at Dynamicweb.Core.Helpers.TextFileHelper.WriteTextFile(String value, String path, Boolean appendToFile, Encoding encoding)
   at CompiledRazorTemplates.Dynamic.RazorEngine_add7ed6b54f7499fb84a28d66c8eaa17.Execute() in D:\dynamicweb.net\Solutions\eldorado.LIVE\Files\Templates\Designs\Catago\_parsed\fullwidth.parsed.cshtml:line 2069
   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.b__0(TextWriter writer)
   at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 2 @using System.Text.RegularExpressions 3 4 @using Dynamicweb.Frontend.Devices 5 @using System 6 @using System.Web 7 @using System.Globalization 8 @using System.Text.RegularExpressions 9 @using Dynamicweb.Environment.Helpers 10 11 @using System.Text.RegularExpressions 12 @using System.Web 13 14 15 @functions{ 16 public class WrapMethods 17 { 18 //Gets the contrasting color 19 public static string getContrastYIQ(string hexcolor) 20 { 21 if (hexcolor != "") 22 { 23 hexcolor = Regex.Replace(hexcolor, "[^0-9a-zA-Z]+", ""); 24 25 int r = Convert.ToByte(hexcolor.Substring(0, 2), 16); 26 int g = Convert.ToByte(hexcolor.Substring(2, 2), 16); 27 int b = Convert.ToByte(hexcolor.Substring(4, 2), 16); 28 int yiq = ((r * 299) + (g * 587) + (b * 114)) / 1000; 29 30 if (yiq >= 128) 31 { 32 return "black"; 33 } 34 else 35 { 36 return "white"; 37 } 38 } 39 else 40 { 41 return "black"; 42 } 43 } 44 45 46 //Truncate text 47 public static string Truncate (string value, int count, bool strip=true) 48 { 49 if (strip == true){ 50 value = StripHtmlTagByCharArray(value); 51 } 52 53 if (value.Length > count) 54 { 55 value = value.Substring(0, count - 1) + "..."; 56 } 57 58 return value; 59 } 60 61 62 //Strip text from HTML 63 public static string StripHtmlTagByCharArray(string htmlString) 64 { 65 char[] array = new char[htmlString.Length]; 66 int arrayIndex = 0; 67 bool inside = false; 68 69 for (int i = 0; i < htmlString.Length; i++) 70 { 71 char let = htmlString[i]; 72 if (let == '<') 73 { 74 inside = true; 75 continue; 76 } 77 if (let == '>') 78 { 79 inside = false; 80 continue; 81 } 82 if (!inside) 83 { 84 array[arrayIndex] = let; 85 arrayIndex++; 86 } 87 } 88 return new string(array, 0, arrayIndex); 89 } 90 91 //Make the correct count of columns 92 public static string ColumnMaker(int Col, string ScreenSize) 93 { 94 string Columns = ""; 95 96 switch (Col) 97 { 98 case 1: 99 Columns = "col-"+ScreenSize+"-12"; 100 break; 101 102 case 2: 103 Columns = "col-"+ScreenSize+"-6"; 104 break; 105 106 case 3: 107 Columns = "col-"+ScreenSize+"-4"; 108 break; 109 110 case 4: 111 Columns = "col-"+ScreenSize+"-3"; 112 break; 113 114 default: 115 Columns = "col-"+ScreenSize+"-3"; 116 break; 117 } 118 119 return Columns; 120 } 121 122 123 private string Custom(string firstoption, string secondoption) 124 { 125 if (firstoption == "custom") 126 { 127 return secondoption; 128 } 129 else 130 { 131 return firstoption; 132 } 133 } 134 } 135 } 136 137 138 139 140 141 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 142 143 @helper MiniCart() 144 { 145 <div class="dropdown-cart"> 146 <div id="full-cart" class="clearfix"> 147 148 <div class="container-wishlist"> 149 150 <div class="clearfix minicart-content" id="minicart-content"> 151 152 @* Orderlines are rendered from the Ajax template *@ 153 </div> 154 </div> 155 <div class=""> 156 <div class="minicart-content"> 157 158 159 @{ 160 var cartid = GetValue("DwAreaCartPageID"); 161 } 162 <div class="text-center"> 163 <a href="Default.aspx?ID=@cartid" class="read-more" style="width:auto; margin-bottom: 12px;display:block; color:#E6A04B !important; display:none;">@Translate("See all products", "See all products")</a> 164 </div> 165 <a href="Default.aspx?ID=@cartid" class="btn btn-xs btn-primary pull-right hidden">@Translate("Send list", "Send list")</a> 166 167 </div> 168 <div class="row">&nbsp;</div> 169 </div> 170 </div> 171 <div id="empty-cart"> 172 <small>@Translate("No products in wishlist")</small> 173 </div> 174 </div> 175 } 176 177 @{ 178 Regex r = new Regex(@"\d+"); 179 string ordersPageId = r.Match(Pageview.Area.Item["OrdersPageId"].ToString()).Value; 180 string productsPageId = r.Match(Pageview.Area.Item["ProductsPageId"].ToString()).Value; 181 string signInPageId = r.Match(Pageview.Area.Item["SignInPageId"].ToString()).Value; 182 string signUpPageId = r.Match(Pageview.Area.Item["SignUpPageId"].ToString()).Value; 183 string userProfilePageId = r.Match(Pageview.Area.Item["UserProfilePageId"].ToString()).Value; 184 string productsAjaxPageId = r.Match(Pageview.Area.Item["ProductsAjaxPageId"].ToString()).Value; 185 string JSONFeedForCart = r.Match(Pageview.Area.Item["JSONFeedForCart"].ToString()).Value; 186 string ImpersonationPageId = r.Match(Pageview.Area.Item["ImpersonationPageId"].ToString()).Value; 187 string HomePetId = r.Match(Pageview.Area.Item["HomePetId"].ToString()).Value; 188 string HomeRidingId = r.Match(Pageview.Area.Item["HomeRidingId"].ToString()).Value; 189 string HomePetRidingId = r.Match(Pageview.Area.Item["HomePetRidingId"].ToString()).Value; 190 string checkuserpageid = r.Match(Pageview.Area.Item["CheckUserPageId"].ToString()).Value; 191 string newsletterid = "0"; 192 string GTMID = ""; 193 bool hideWishList = false; 194 195 if (GetBoolean("Item.Area.HideTheWishListFunctionality")) 196 { 197 hideWishList = true; 198 } 199 if (!string.IsNullOrWhiteSpace(Pageview.Area.Item["GTM_ID"].ToString())) 200 { 201 GTMID = Pageview.Area.Item["GTM_ID"].ToString(); 202 } 203 if (GetBoolean("Item.Area.ShowNewsletterPopup")) 204 { 205 newsletterid = GetString("Item.Area.NewsletterSignupParagraphId"); 206 } 207 } 208 209 <!DOCTYPE html> 210 <html> 211 <head> 212 <meta charset="utf-8"> 213 <title>@GetValue("Title")</title> 214 @GetValue("MetaTags") 215 @GetValue("CopyRightNotice") 216 217 218 <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1"> 219 <meta name="robots" content="index, follow"> 220 221 @{ 222 string MetaDescription = GetString("Meta.Description"); 223 string MetaKeywords = GetString("Meta.Keywords"); 224 } 225 226 227 228 @if (!string.IsNullOrWhiteSpace(GTMID)) 229 { 230 <!-- Google Tag Manager --> 231 <script> 232 (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': 233 new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], 234 j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 235 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); 236 })(window,document,'script','dataLayer','@GTMID');</script> 237 <!-- End Google Tag Manager --> 238 } 239 240 <!-- Facebook Admin --> 241 @if (!string.IsNullOrWhiteSpace(GetString("Item.Area.FacebookCommendAdmin"))) 242 { 243 string fbadmin = GetString("Item.Area.FacebookCommendAdmin"); 244 <meta property="fb:admins" content="@fbadmin"> 245 } 246 247 <!-- Essential styles --> 248 <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" type="text/css"> 249 <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" type="text/css"> 250 <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/fancybox/2.1.5/jquery.fancybox.min.css" media="screen"> 251 <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/flag-icon-css/2.5.0/css/flag-icon.min.css" type="text/css"> 252 <link href="https://fonts.googleapis.com/css?family=Oswald" rel="stylesheet"> 253 <!-- Mobile menu styles --> 254 <link href="/Files/Templates/Designs/Catago/css/jasny-bootstrap.min.css" rel="stylesheet" type="text/css" media="screen"> 255 256 <!-- Favicon --> 257 @{ 258 var favicon = @GetString("Item.Area.Favicon"); 259 } 260 <link href="@favicon" rel="icon" type="image/png"> 261 262 <!-- Variables --> 263 @{ 264 var attrValue = ""; 265 string currentpageid = GetString("DwPageID"); 266 string firstpageid = GetString("DwAreaFirstActivePageID"); 267 string favListpageId = GetString("Item.Area.FavoritesPageId"); 268 string searchplaceholder = Translate("Search products", "Search products"); 269 string searchpage = GetString("Item.Area.ShowSearchPage"); 270 271 var cartid = GetValue("DwAreaCartPageID"); 272 273 DateTime areaUpdated = (DateTime)Pageview.Area.Audit.LastModifiedAt; 274 string cssPath = HttpContext.Current.Server.MapPath("/Files/Templates/Designs/Dwsimple/css/DWGlobalStylesSite" + GetString("DwAreaID") + "_auto.min.css"); 275 DateTime lastWriteTime = System.IO.File.GetLastWriteTime(cssPath); 276 bool writeCss = false; 277 string css = String.Empty; 278 string bgbuttonnews = GetString("Item.Area.BackgroundColorButtonSignup"); 279 string colorbuttonnews = GetString("Item.Area.ColorTextOnButtonSignupNewsletter"); 280 string bgwrapnews = GetString("Item.Area.BackgroundColorSignUp"); 281 string colorwrapnews = GetString("Item.Area.ColorTextOnButtonSignupContainerNewsletter"); 282 string colorbtnnbox = GetString("Item.Area.ColorTextButtonInsidePopupBox"); 283 string bgbtnnbox = GetString("Item.Area.BackgroundButtonInsidePopupBox"); 284 writeCss = true; 285 286 } 287 @if (GetString("DW_extranet_Groups").Contains("6828")) 288 { 289 firstpageid = HomePetId; 290 } 291 @if (GetString("DW_extranet_Groups").Contains("6829")) 292 { 293 firstpageid = HomeRidingId; 294 } 295 @if (GetString("DW_extranet_Groups").Contains("6830")) 296 { 297 firstpageid = HomePetRidingId; 298 } 299 <!--FONT SETTINGS--> 300 @functions{ 301 public class FontSettings 302 { 303 public class Logo 304 { 305 public static string FontFamily { get; set; } 306 public static string FontSize { get; set; } 307 public static string FontWeight { get; set; } 308 public static string Color { get; set; } 309 public static string LineHeight { get; set; } 310 public static string Casing { get; set; } 311 public static string LetterSpacing { get; set; } 312 } 313 314 public class Slogan 315 { 316 public static string FontFamily { get; set; } 317 public static string FontSize { get; set; } 318 public static string FontWeight { get; set; } 319 public static string Color { get; set; } 320 public static string LineHeight { get; set; } 321 public static string Casing { get; set; } 322 public static string LetterSpacing { get; set; } 323 } 324 325 public class H1 326 { 327 public static string FontFamily { get; set; } 328 public static string FontSize { get; set; } 329 public static string FontWeight { get; set; } 330 public static string Color { get; set; } 331 public static string LineHeight { get; set; } 332 public static string Casing { get; set; } 333 public static string LetterSpacing { get; set; } 334 } 335 336 public class H2 337 { 338 public static string FontFamily { get; set; } 339 public static string FontSize { get; set; } 340 public static string FontWeight { get; set; } 341 public static string Color { get; set; } 342 public static string LineHeight { get; set; } 343 public static string Casing { get; set; } 344 public static string LetterSpacing { get; set; } 345 } 346 347 public class Body 348 { 349 public static string FontFamily { get; set; } 350 public static string FontSize { get; set; } 351 public static string FontWeight { get; set; } 352 public static string Color { get; set; } 353 public static string LineHeight { get; set; } 354 public static string Casing { get; set; } 355 public static string LetterSpacing { get; set; } 356 } 357 } 358 359 private void InitFontSettings() 360 { 361 //LOGO 362 FontSettings.Logo.FontFamily = CustomFont(GetString("Item.Area.LogoFont.Font"), GetString("Item.Area.LogoFont.CustomFont")); 363 FontSettings.Logo.FontSize = GetString("Item.Area.LogoFont.Size") + "px"; 364 FontSettings.Logo.FontWeight = CheckExistence(GetString("Item.Area.LogoFont.Weight"), "normal"); 365 FontSettings.Logo.LineHeight = CheckExistence(GetString("Item.Area.LogoFont.LineHeight"), "1"); 366 FontSettings.Logo.LetterSpacing = GetString("Item.Area.LogoFont.LetterSpacing") + "px"; 367 FontSettings.Logo.Casing = GetString("Item.Area.LogoFont.Casing"); 368 FontSettings.Logo.Color = GetString("Item.Area.LogoFont.Color.Color"); 369 370 371 //SLOGAN 372 FontSettings.Slogan.FontFamily = CustomFont(GetString("Item.Area.LogoSloganFont.Font"), GetString("Item.Area.LogoSloganFont.CustomFont")); 373 FontSettings.Slogan.FontSize = GetString("Item.Area.LogoSloganFont.Size") + "px"; 374 FontSettings.Slogan.FontWeight = CheckExistence(GetString("Item.Area.LogoSloganFont.Weight"), "normal"); 375 FontSettings.Slogan.LineHeight = CheckExistence(GetString("Item.Area.LogoSloganFont.LineHeight"), "1"); 376 FontSettings.Slogan.LetterSpacing = GetString("Item.Area.LogoSloganFont.LetterSpacing") + "px"; 377 FontSettings.Slogan.Casing = GetString("Item.Area.LogoSloganFont.Casing"); 378 FontSettings.Slogan.Color = GetString("Item.Area.LogoSloganFont.Color.Color"); 379 380 381 //HEADINGS 382 FontSettings.H1.FontFamily = CustomFont(GetString("Item.Area.HeadingsH1.Font"), GetString("Item.Area.HeadingsH1.CustomFont")); 383 FontSettings.H1.FontSize = GetString("Item.Area.HeadingsH1.Size") + "px"; 384 FontSettings.H1.FontWeight = CheckExistence(GetString("Item.Area.HeadingsH1.Weight"), "normal"); 385 FontSettings.H1.LineHeight = CheckExistence(GetString("Item.Area.HeadingsH1.LineHeight"), "1"); 386 FontSettings.H1.LetterSpacing = GetString("Item.Area.HeadingsH1.LetterSpacing") + "px"; 387 FontSettings.H1.Casing = GetString("Item.Area.HeadingsH1.Casing"); 388 FontSettings.H1.Color = GetString("Item.Area.HeadingsH1.Color.Color"); 389 390 FontSettings.H2.FontFamily = CustomFont(GetString("Item.Area.HeadingsH2.Font"), GetString("Item.Area.HeadingsH2.CustomFont")); 391 FontSettings.H2.FontSize = GetString("Item.Area.HeadingsH2.Size") + "px"; 392 FontSettings.H2.FontWeight = CheckExistence(GetString("Item.Area.HeadingsH2.Weight"), "normal"); 393 FontSettings.H2.LineHeight = CheckExistence(GetString("Item.Area.HeadingsH2.LineHeight"), "1"); 394 FontSettings.H2.LetterSpacing = GetString("Item.Area.HeadingsH2.LetterSpacing") + "px"; 395 FontSettings.H2.Casing = GetString("Item.Area.HeadingsH2.Casing"); 396 FontSettings.H2.Color = GetString("Item.Area.HeadingsH2.Color.Color"); 397 398 399 //BODY 400 FontSettings.Body.FontFamily = CustomFont(GetString("Item.Area.BodyFont.Font"), GetString("Item.Area.BodyFont.CustomFont")); 401 FontSettings.Body.FontSize = GetString("Item.Area.BodyFont.Size") + "px"; 402 FontSettings.Body.FontWeight = CheckExistence(GetString("Item.Area.BodyFont.Weight"), "normal"); 403 FontSettings.Body.LineHeight = CheckExistence(GetString("Item.Area.BodyFont.LineHeight"), "1"); 404 FontSettings.Body.LetterSpacing = GetString("Item.Area.BodyFont.LetterSpacing") + "px"; 405 FontSettings.Body.Casing = GetString("Item.Area.BodyFont.Casing"); 406 FontSettings.Body.Color = GetString("Item.Area.BodyFont.Color.Color"); 407 408 409 gfonts.Add(FontSettings.Logo.FontFamily, ""); 410 411 if (!gfonts.ContainsKey(FontSettings.Slogan.FontFamily)) 412 { 413 gfonts.Add(FontSettings.Slogan.FontFamily, ""); 414 } 415 if (!gfonts.ContainsKey(FontSettings.H1.FontFamily)) 416 { 417 gfonts.Add(FontSettings.H1.FontFamily, ""); 418 } 419 if (!gfonts.ContainsKey(FontSettings.H2.FontFamily)) 420 { 421 gfonts.Add(FontSettings.H2.FontFamily, ""); 422 } 423 if (!gfonts.ContainsKey(FontSettings.Body.FontFamily)) 424 { 425 gfonts.Add(FontSettings.Body.FontFamily, ""); 426 } 427 428 } 429 430 private string CustomFont(string firstfont, string secondfont) 431 { 432 if (firstfont == "custom") 433 { 434 return secondfont; 435 } 436 else 437 { 438 return firstfont; 439 } 440 } 441 442 private string CheckExistence(string stringitem, string defaultvalue) 443 { 444 if (!string.IsNullOrWhiteSpace(stringitem)) 445 { 446 return stringitem; 447 } 448 else 449 { 450 return defaultvalue; 451 } 452 } 453 454 private System.Collections.Generic.Dictionary<string, object> gfonts = new System.Collections.Generic.Dictionary<string, object>(); 455 } 456 457 @{ 458 InitFontSettings(); 459 } 460 461 @helper GoogleFonts() 462 { 463 if (gfonts != null) 464 { 465 foreach (var item in gfonts) 466 { 467 if (@item.Key.Contains("vista-sans-narrow") || @item.Key.Contains("vista-sans") || @item.Key=="" || @item.Key==null) 468 { 469 470 } 471 else 472 { 473 <link rel="stylesheet" type="text/css" href="//fonts.googleapis.com/css?family=@item.Key:100,200,300,400,500,600,700,800,900"> 474 } 475 476 } 477 } 478 } 479 480 481 @functions{ 482 public string FontStylesCSS() 483 { 484 string CssString = @" 485 .dw-logotext { 486 font-family: " + FontSettings.Logo.FontFamily + @"; 487 font-size: " + FontSettings.Logo.FontSize + @"; 488 font-weight: " + FontSettings.Logo.FontWeight + @"; 489 line-height: " + FontSettings.Logo.LineHeight + @" !important; 490 letter-spacing: " + FontSettings.Logo.LetterSpacing + @"; 491 text-transform: " + FontSettings.Logo.Casing + @"; 492 color: " + FontSettings.Logo.Color + @"; 493 } 494 495 .dw-slogantext { 496 font-family: " + FontSettings.Slogan.FontFamily + @"; 497 font-size: " + FontSettings.Slogan.FontSize + @"; 498 font-weight: " + FontSettings.Slogan.FontWeight + @"; 499 line-height: " + FontSettings.Slogan.LineHeight + @" !important; 500 letter-spacing: " + FontSettings.Slogan.LetterSpacing + @"; 501 text-transform: " + FontSettings.Slogan.Casing + @"; 502 color: " + FontSettings.Slogan.Color + @"; 503 } 504 505 h1 { 506 font-family: " + FontSettings.H1.FontFamily + @" !important; 507 font-size: " + FontSettings.H1.FontSize + @"; 508 color: " + FontSettings.H1.Color + @"; 509 line-height: " + FontSettings.H1.LineHeight + @" !important; 510 text-transform: " + FontSettings.H1.Casing + @"; 511 font-weight: " + FontSettings.H1.FontWeight + @"; 512 letter-spacing: " + FontSettings.H1.LetterSpacing + @" !important; 513 } 514 515 516 h2, h3, h4, h5, h6 { 517 margin-top: 0.7em; 518 margin-bottom: 0.7em; 519 520 font-family: " + FontSettings.H2.FontFamily + @" !important; 521 font-size: " + FontSettings.H2.FontSize + @"; 522 color: " + FontSettings.H2.Color + @"; 523 line-height: " + FontSettings.H2.LineHeight + @"; 524 text-transform: " + FontSettings.H2.Casing + @" !important; 525 font-weight: " + FontSettings.H2.FontWeight + @" !important; 526 letter-spacing: " + FontSettings.H2.LetterSpacing + @" !important; 527 } 528 529 h4, h5, h6 { 530 font-size: 16px !important; 531 } 532 533 body { 534 font-family: " + FontSettings.Body.FontFamily + @" !important; 535 font-size: " + FontSettings.Body.FontSize + @"; 536 color: " + FontSettings.Body.Color + @"; 537 line-height: " + FontSettings.Body.LineHeight + @" !important; 538 text-transform: " + FontSettings.Body.Casing + @"; 539 font-weight: " + FontSettings.Body.FontWeight + @"; 540 letter-spacing: " + FontSettings.Body.LetterSpacing + @" !important; 541 } 542 543 .navbar-wp .navbar-nav > li > a { 544 font-family: " + FontSettings.Body.FontFamily + @" !important; 545 } 546 547 .section-title { 548 margin-top: 0; 549 margin-bottom: 0.7em; 550 } 551 "; 552 return CssString; 553 } 554 } 555 @GoogleFonts() 556 557 <!-- GENERAL/COLOR SETTINGS --> 558 @functions{ 559 public class ColorSettings 560 { 561 public class Color 562 { 563 public static string Primary { get; set; } 564 public static string Secondary { get; set; } 565 public static string NavbarFont { get; set; } 566 public static string Footer { get; set; } 567 public static string FooterFont { get; set; } 568 569 public static string Sticker { get; set; } 570 public static string Price { get; set; } 571 public static string Cart { get; set; } 572 } 573 } 574 575 private void InitColorSettings() 576 { 577 ColorSettings.Color.Primary = GetString("Item.Area.ColorsPrimary.Color"); 578 ColorSettings.Color.Secondary = GetString("Item.Area.ColorsSecondary.Color"); 579 580 ColorSettings.Color.NavbarFont = GetString("Item.Area.NavbarFontColor"); 581 582 if (string.IsNullOrWhiteSpace(ColorSettings.Color.NavbarFont)) 583 { 584 ColorSettings.Color.NavbarFont = WrapMethods.getContrastYIQ(ColorSettings.Color.Secondary); 585 } 586 587 ColorSettings.Color.Footer = GetString("Item.Area.ColorsFooterColor.Color"); 588 ColorSettings.Color.FooterFont = WrapMethods.getContrastYIQ(ColorSettings.Color.Footer); 589 590 ColorSettings.Color.Price = GetString("Item.Area.EcommercePriceColor.Color"); 591 ColorSettings.Color.Sticker = GetString("Item.Area.EcommerceDiscountStickerColor.Color"); 592 ColorSettings.Color.Cart = GetString("Item.Area.EcommerceCartButtonColor.Color"); 593 } 594 595 public string GetColorSettings() 596 { 597 string CssString = @" 598 a:hover, a:focus, a:active { 599 color: @Primary; 600 } 601 602 .navbar-wp, .navbar-wp.affix, .navbar-wp .navbar-nav > li > a { 603 color: @NavbarFont; 604 } 605 ul.dw-categories li > a { 606 display: block; 607 padding: 7px 15px; 608 color: @NavbarFont; 609 } 610 ul.M3 li > a { 611 612 } 613 .navbar-wp .navbar-nav > li > a span::after, .navbar-wp .navbar-nav > div > a.dropdown-toggle span::after { 614 background-color:@Primary !important; 615 } 616 ul.dw-categories li:hover > a { 617 color: inherit; 618 } 619 ul.dw-categories li:hover > a:hover { 620 color: inherit; 621 } 622 .navbar-wp .navbar-nav > .active > a, .navbar-wp .navbar-nav > .active > a:hover, .navbar-wp .navbar-nav > .active > a:focus { 623 color: @NavbarFont; 624 } 625 626 .navbar-wp .navbar-nav > li > a:hover, .navbar-wp .navbar-nav > li > a:focus { 627 border-top: 0px solid @Secondary; 628 color: @NavbarFont; 629 } 630 631 .navbar-wp .navbar-nav > li > a span:after, .navbar-wp .navbar-nav > div > a.dropdown-toggle span:after{ 632 background-color: @NavbarFont; 633 } 634 635 .navbar-wp .megamenu > li:hover > a { 636 color: @Primary !important; 637 } 638 639 .btn-dw-primary { 640 color: #FFF; 641 background-color: @Primary; 642 border-color: @Primary; 643 } 644 645 .btn-dw-secondary { 646 color: @NavbarFont; 647 background-color: @Secondary; 648 border-color: @Secondary; 649 } 650 651 .btn-dw-cart { 652 color: #FFF; 653 background-color: @Cart; 654 border-color: @Cart; 655 } 656 657 .dw-section-title { 658 border-color: @Secondary; 659 } 660 661 .dw-minicart-update { 662 color: #FFF !important; 663 background-color: @Primary; 664 transition: all 0.3s ease-in-out 0s; 665 } 666 667 .pagination > li > a, .pagination > li > a:hover, .pagination > li > a:focus, .pagination > li > a:active { 668 color: @Primary !important; 669 } 670 671 .form-control:hover, .form-control:focus, .form-control:active, .pagination > .active > a { 672 border-color: @Primary !important; 673 } 674 675 .bg-2 { 676 background: @Primary !important; 677 } 678 679 .blockquote-1:hover { 680 border-color: @Primary !important; 681 } 682 683 .navbar-wp .navbar-nav > li > a.dropdown-form-toggle, .navbar-wp .navbar-nav > li > a.dropdown-form-toggle:hover, .navbar-wp .navbar-nav > li > a.dropdown-form-toggle:focus { 684 color: @Primary; 685 } 686 687 .navbar-wp .navbar-nav > .open > a.dropdown-form-toggle, .navbar-wp .navbar-nav > .open > a.dropdown-form-toggle:hover, .navbar-wp .navbar-nav > .open > a.dropdown-form-toggle:focus { 688 color: @Primary; 689 } 690 691 .navbar-wp .navbar-nav > li > a:hover, .navbar-wp .navbar-nav > li > a:focus { 692 border: 0px solid @Primary; 693 } 694 695 .navbar-wp .navbar-toggle:hover, .navbar-wp .navbar-toggle:focus { 696 background-color: @Primary !important; 697 border-color: @Primary !important; 698 } 699 700 .navbar-wp .dropdown-menu { 701 border-top: 1px solid @Primary !important; 702 border-bottom: 3px solid @Primary !important; 703 } 704 705 .navbar-wp .dropdown-menu > li > a:hover { 706 background: @Primary !important; 707 color: #fff; 708 } 709 710 .navbar-wp .dropdown-menu .active { 711 background: @Primary !important; 712 color: #fff; 713 } 714 715 .navbar-wp.navbar-contrasted .dropdown-menu > li > a:hover { 716 background: @Primary !important; 717 } 718 719 .nav > ul > li > a:hover { 720 color: @Primary; 721 } 722 723 .lw .w-box.w-box-inverse .thmb-img i { 724 color: @Primary !important; 725 } 726 727 .w-box.w-box-inverse .thmb-img:hover i { 728 background: @Primary !important; 729 } 730 731 .c-box { 732 border: 1px solid @Primary !important; 733 } 734 735 .c-box .c-box-header { 736 background: @Primary !important; 737 } 738 739 .w-section .aside-feature:hover .icon-feature, .w-section .aside-feature:hover h4 { 740 color: @Primary !important; 741 } 742 743 .layer-slider-wrapper .title.title-base { 744 background: @Primary !important; 745 } 746 747 .layer-slider-wrapper .subtitle { 748 color: @Primary !important; 749 } 750 751 .layer-slider-wrapper .list-item { 752 color: @Primary !important; 753 } 754 755 .box-element.box-element-bordered { 756 border: 1px solid @Primary !important; 757 } 758 759 .carousel-2 .carousel-indicators .active { 760 background-color: @Primary !important; 761 } 762 763 .carousel-2 .carousel-nav a { 764 color: @Primary !important; 765 } 766 767 .carousel-2 .carousel-nav a:hover { 768 background: @Primary !important; 769 } 770 771 .carousel-3 .carousel-nav a { 772 color: @Primary !important; 773 } 774 775 .carousel-3 .carousel-nav a:hover { 776 background: @Primary !important; 777 } 778 779 .like-button .button.liked i { 780 color: @Primary !important; 781 } 782 783 ul.list-listings li.featured { 784 border-color: @Primary !important; 785 } 786 787 ul.list-check li i { 788 color: @Primary !important; 789 } 790 791 ul.dw-categories li a:hover, ul.dw-categories a:focus, ul.dw-categories a:active{ 792 color: @NavbarFont; 793 background-color: @Primary; 794 border-color: @Primary; 795 } 796 797 ul.categories li a:hover, ul.categories a:focus, ul.categories a:active{ 798 color: @NavbarFont; 799 background-color: @Primary; 800 border-color: @Primary; 801 } 802 803 .timeline .event:nth-child(2n):before { 804 background-color: @Primary !important; 805 } 806 807 .timeline .event:nth-child(2n-1):before { 808 background-color: @Primary !important; 809 } 810 811 #toTopHover { 812 background-color: @Primary !important; 813 } 814 815 .tags-list li { 816 border: 1px solid @Primary !important; 817 color: @Primary !important; 818 } 819 820 .tags-list li:hover, 821 a.open-panel { 822 background-color: @Primary !important; 823 } 824 825 .nav-pills > li.active > a, .nav-pills > li.active > a:hover, .nav-pills > li.active > a:focus, 826 .panel-group .panel-heading a i, 827 .tags-list li a { 828 color: @NavbarFont !important; 829 } 830 831 .nav-pills > li > a:hover, .nav-pills > li > a:focus { 832 color: @NavbarFont !important; 833 background: none repeat scroll 0% 0% @Secondary !important; 834 } 835 836 footer { 837 background: @Footer !important; 838 } 839 840 footer h4 { 841 color: @FooterFont !important; 842 } 843 844 footer a { 845 color: @FooterFont !important; 846 } 847 848 footer a:hover, footer a:focus, footer a:active { 849 color: @Primary !important; 850 } 851 852 footer p { 853 color: @FooterFont !important; 854 } 855 856 footer ul > li { 857 color: @FooterFont !important; 858 } 859 860 footer hr { 861 border-color: @FooterFont 862 } 863 864 865 /* Button colors */ 866 .btn-base { 867 color: @NavbarFont !important; 868 background-color: @Secondary !important; 869 border: 1px solid @Secondary !important; 870 } 871 872 .btn-base:before { 873 background-color: @Secondary !important; 874 } 875 876 .btn-base:hover:before, .btn-base:focus:before, .btn-base:active:before { 877 color: @NavbarFont !important; 878 background-color: @Primary !important; 879 border-color: @Primary !important; 880 } 881 882 .btn-icon:before { 883 transition: none !important; 884 } 885 886 .btn-base:hover, .btn-base:focus, .btn-base:active, .btn-base.active, .open .dropdown-toggle.btn-base { 887 color: @NavbarFont !important; 888 background-color: @Primary !important; 889 border-color: @Primary !important; 890 } 891 892 .btn-primary { 893 background-color: @Primary !important; 894 border-color: @Primary !important; 895 } 896 897 .open .dropdown-toggle.btn-primary { 898 background-color: @Primary !important; 899 border-color: @Primary !important; 900 } 901 902 /* Dropdown-menu */ 903 .dropdown-menu > .active > a, .dropdown-menu > .active > a:hover, .dropdown-menu > .active > a:focus { 904 background: @Primary !important; 905 color: #fff !important; 906 } 907 908 /* Ecom settings */ 909 .ribbon.base, .ball { 910 background: @Sticker !important; 911 color: #fff; 912 border-right: 5px solid @Sticker !important; 913 } 914 915 .ribbon.base:before { 916 border-top: 27px solid @Sticker !important; 917 } 918 919 .ribbon.base:after { 920 border-bottom: 27px solid @Sticker !important; 921 } 922 923 .price { 924 color: @Price !important; 925 } 926 927 .discount-sticker { 928 background-color: @Sticker !important; 929 } 930 931 .bs-callout-primary { 932 border-left-color: @Primary !important; 933 } 934 935 .ratings .fa-star { 936 color: @Secondary !important; 937 } 938 939 .feature-label { 940 color: @Secondary !important; 941 }"; 942 943 return ParseCSSToString(CssString); 944 } 945 946 private string ParseCSSToString(string TheString) 947 { 948 TheString = TheString.Replace("@Primary", ColorSettings.Color.Primary); 949 TheString = TheString.Replace("@Secondary", ColorSettings.Color.Secondary); 950 TheString = TheString.Replace("@NavbarFont", ColorSettings.Color.NavbarFont); 951 TheString = TheString.Replace("@FooterFont", ColorSettings.Color.FooterFont); 952 TheString = TheString.Replace("@Footer", ColorSettings.Color.Footer); 953 954 TheString = TheString.Replace("@Sticker", ColorSettings.Color.Sticker); 955 TheString = TheString.Replace("@Price", ColorSettings.Color.Price); 956 TheString = TheString.Replace("@Cart", ColorSettings.Color.Cart); 957 958 959 System.Text.StringBuilder sb = new System.Text.StringBuilder(); 960 961 foreach(var item in TheString.Split(new string[] { Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries)) 962 { 963 sb.AppendLine(item); 964 } 965 966 return sb.ToString(); 967 } 968 } 969 970 @{ 971 InitColorSettings(); 972 } 973 974 975 976 @using System.Drawing 977 @using System.Net 978 979 980 @functions{ 981 public class GeneralSettings 982 { 983 984 public class Header 985 { 986 public static string Mode { get; set; } 987 public static string Classes { get; set; } 988 public static bool Show { get; set; } 989 public static string Background { get; set; } 990 public static bool ShowFrontpageImage { get; set; } 991 } 992 993 public class Logo 994 { 995 public static string Image { get; set; } 996 public static string ContrastImage { get; set; } 997 public static string Text { get; set; } 998 public static string Slogan { get; set; } 999 public static string SecondaryColor { get; set; } 1000 } 1001 1002 public class Navigation 1003 { 1004 public static string Position { get; set; } 1005 public static bool IsMegamenu { get; set; } 1006 public static string InvertedPosition { get; set; } 1007 public static string StickyMenu { get; set; } 1008 public static string SelectionMode { get; set; } 1009 public static string SelectionStyle { get; set; } 1010 public static int SelectionWeight { get; set; } 1011 public static bool Case { get; set; } 1012 1013 public static string BreadcrumbMode { get; set; } 1014 public static string BreadcrumbAlign { get; set; } 1015 1016 public static string LeftmenuMode { get; set; } 1017 1018 public static string ButtonDesign { get; set; } 1019 } 1020 1021 public class Headings 1022 { 1023 public static string Mode { get; set; } 1024 } 1025 1026 public class Background 1027 { 1028 public static string Color { get; set; } 1029 public static string Image { get; set; } 1030 public static string CustomImage { get; set; } 1031 public static bool GradientColor { get; set; } 1032 public static string GradientPercentage { get; set; } 1033 public static string Style { get; set; } 1034 public static string Position { get; set; } 1035 } 1036 1037 public class Site 1038 { 1039 public static bool Shadow { get; set; } 1040 public static string LayoutMode { get; set; } 1041 } 1042 1043 public class Images 1044 { 1045 public static bool RoundCorners { get; set; } 1046 } 1047 1048 public class Ecommerce 1049 { 1050 public static string EcomListDesign { get; set; } 1051 public static string EcomCardDesign { get; set; } 1052 } 1053 } 1054 1055 private void InitGeneralSettings() 1056 { 1057 //Header settings 1058 GeneralSettings.Header.Mode = GetString("Item.Area.HeaderLayoutMode"); 1059 GeneralSettings.Header.Show = GetBoolean("Item.Area.HeaderShow"); 1060 GeneralSettings.Header.Background = GetString("Item.Area.NavigationNavbarBackground"); 1061 GeneralSettings.Header.ShowFrontpageImage = GetBoolean("Item.Area.HeaderFrontpageImage"); 1062 1063 if (GeneralSettings.Header.Mode == "solid"){ 1064 GeneralSettings.Header.Classes = ""; 1065 } 1066 1067 if (GeneralSettings.Header.Mode == "cover" || GeneralSettings.Header.Mode == "mobile"){ 1068 GeneralSettings.Header.Classes = "header-alpha header-cover"; 1069 } 1070 1071 1072 //Logo settings 1073 GeneralSettings.Logo.Image = GetString("Item.Area.GeneralLogo"); 1074 GeneralSettings.Logo.Text = GetString("Item.Area.GeneralLogoText"); 1075 GeneralSettings.Logo.Slogan = GetString("Item.Area.LogoSlogan"); 1076 GeneralSettings.Logo.SecondaryColor = GetString("Item.Area.LogoSecondColor.Color"); 1077 1078 if (!string.IsNullOrWhiteSpace(GetString("Item.Area.LogoContrastImage"))) { 1079 GeneralSettings.Logo.ContrastImage = GetString("Item.Area.LogoContrastImage"); 1080 } else { 1081 GeneralSettings.Logo.ContrastImage = GetString("Item.Area.GeneralLogo"); 1082 } 1083 1084 1085 //Navigation settings 1086 GeneralSettings.Navigation.Position = GetString("Item.Area.NavigationPosition"); 1087 GeneralSettings.Navigation.StickyMenu = "off"; 1088 GeneralSettings.Navigation.IsMegamenu = GetBoolean("Item.Area.IsMegamenu"); 1089 1090 if (GetBoolean("Item.Area.NavigationSticky")) { 1091 if (GeneralSettings.Header.Show) 1092 { 1093 if (GeneralSettings.Header.Mode == "cover") 1094 { 1095 GeneralSettings.Navigation.StickyMenu = "44"; //"data-spy=\"affix\" data-offset-top=\"44\" data-offset-bottom=\"300\""; 1096 } 1097 else 1098 { 1099 int offset = ImageHeight()+28; 1100 1101 GeneralSettings.Navigation.StickyMenu = offset.ToString(); // "data-spy=\"affix\" data-offset-top=\"" + offset.ToString() + "\" data-offset-bottom=\"300\""; 1102 } 1103 } 1104 else 1105 { 1106 GeneralSettings.Navigation.StickyMenu = "5"; // "data-spy=\"affix\" data-offset-top=\"5\" data-offset-bottom=\"300\""; 1107 } 1108 } 1109 1110 if (GeneralSettings.Navigation.Position == "left") { 1111 GeneralSettings.Navigation.InvertedPosition = "right"; 1112 } 1113 else 1114 { 1115 GeneralSettings.Navigation.InvertedPosition = "left"; 1116 } 1117 1118 GeneralSettings.Navigation.SelectionMode = GetString("Item.Area.NavigationSelectionMode"); 1119 GeneralSettings.Navigation.SelectionStyle = ""; 1120 GeneralSettings.Navigation.SelectionWeight = GetInteger("Item.Area.SelectionWeight"); 1121 1122 if (GeneralSettings.Navigation.SelectionMode == "arrow") { 1123 GeneralSettings.Navigation.SelectionStyle = "navbar-arrow"; 1124 } 1125 1126 GeneralSettings.Navigation.Case = GetBoolean("Item.Area.NavigationUppercase"); 1127 1128 GeneralSettings.Navigation.BreadcrumbMode = GetString("Item.Area.NavigationBreadcrumbLayout"); 1129 GeneralSettings.Navigation.BreadcrumbAlign = GetString("Item.Area.NavigationBreadcrumbAlign"); 1130 1131 GeneralSettings.Navigation.LeftmenuMode = GetString("Item.Area.NavigationLeftNavigationMode"); 1132 1133 GeneralSettings.Navigation.ButtonDesign = GetString("Item.Area.NavigationButtonDesign"); 1134 1135 1136 //Background settings 1137 GeneralSettings.Background.Image = GetString("Item.Area.BackgroundImage.Image.Image"); 1138 GeneralSettings.Background.CustomImage = GetString("Item.Area.BackgroundImage.Image.CustomImage"); 1139 GeneralSettings.Background.Color = GetString("Item.Area.BackgroundImage.Color.Color"); 1140 GeneralSettings.Background.GradientColor = GetBoolean("Item.Area.BackroundGradientColor"); 1141 GeneralSettings.Background.GradientPercentage = GetString("Item.Area.GradientPercentage"); 1142 1143 1144 if (@GetString("Item.Area.BackgroundFixed") == "True") 1145 { 1146 GeneralSettings.Background.Position = "fixed"; 1147 } 1148 else 1149 { 1150 GeneralSettings.Background.Position = ""; 1151 } 1152 1153 1154 if (GeneralSettings.Background.Image == "none") 1155 { 1156 GeneralSettings.Background.Style = ""; 1157 } 1158 else if (GeneralSettings.Background.Image == "custom") 1159 { 1160 if (!string.IsNullOrWhiteSpace(GeneralSettings.Background.CustomImage)) 1161 { 1162 GeneralSettings.Background.Style = "background: url('/Admin/Public/GetImage.ashx?width=1920&amp;Crop=1&amp;Compression=75&amp;image=" + GeneralSettings.Background.CustomImage + "') " + GeneralSettings.Background.Position + " !important; "; 1163 } 1164 } 1165 else 1166 { 1167 GeneralSettings.Background.Style = "background: url('/Admin/Public/GetImage.ashx?width=1920&amp;Crop=1&amp;Compression=75&amp;image=/Files/Templates/Designs/Dwsimple/images/background/" + GeneralSettings.Background.Image + "') " + GeneralSettings.Background.Position + " !important; "; 1168 } 1169 1170 1171 //Headings settings 1172 GeneralSettings.Headings.Mode = GetString("Item.Area.AdvHeadingsMode"); 1173 1174 1175 //Site settings 1176 GeneralSettings.Site.Shadow = GetBoolean("Item.Area.BackgroundSiteShadow"); 1177 GeneralSettings.Site.LayoutMode = GetString("Item.Area.LayoutMode"); 1178 1179 if (GeneralSettings.Site.LayoutMode == "boxed"){ 1180 GeneralSettings.Site.LayoutMode = "body-" + GeneralSettings.Site.LayoutMode; 1181 GeneralSettings.Header.Classes += " header-boxed"; 1182 } 1183 1184 1185 //Image settings 1186 GeneralSettings.Images.RoundCorners = GetBoolean("Item.Area.LayoutRoundCorners"); 1187 1188 //Ecommerce settings 1189 GeneralSettings.Ecommerce.EcomListDesign = GetString("Item.Area.EcommerceProductCardDesign"); 1190 GeneralSettings.Ecommerce.EcomCardDesign = GetString("Item.Area.EcommerceProductCardDesign"); 1191 } 1192 1193 public string GetGeneralCSS() 1194 { 1195 string CssString = ""; 1196 int SelectionWeight = GeneralSettings.Navigation.SelectionWeight; 1197 1198 //Site settings 1199 if (GetString("Item.Area.LogoFont.Color.Color") == "#FFF" || GetString("Item.Area.LogoFont.Color.Color") == "#FFFFFF") 1200 { 1201 int offset = ImageHeight()+28; 1202 1203 CssString += @" 1204 .dw-offsetmenu-logo { 1205 color: #333 !important; 1206 }"; 1207 } 1208 1209 if (!string.IsNullOrWhiteSpace(GeneralSettings.Background.Color)) 1210 { 1211 CssString += @" 1212 body { 1213 background-color: " + GeneralSettings.Background.Color + @"; 1214 background-size: cover; 1215 overflow-y: scroll; 1216 }"; 1217 } 1218 1219 if (GeneralSettings.Background.GradientColor) 1220 { 1221 CssString += @" 1222 body { 1223 background: -webkit-linear-gradient(bottom, rgba(0, 0, 0, 0." + GeneralSettings.Background.GradientPercentage + @") 0%, rgba(0, 0, 0, 0) 100%); 1224 background: -o-linear-gradient(bottom, rgba(0, 0, 0, 0." + GeneralSettings.Background.GradientPercentage + @") 0%, rgba(0, 0, 0, 0) 100%); 1225 background: -ms-linear-gradient(bottom, rgba(0, 0, 0, 0." + GeneralSettings.Background.GradientPercentage + @") 0%, rgba(0, 0, 0, 0) 100%); 1226 background: -moz-linear-gradient(bottom, rgba(0, 0, 0, 0." + GeneralSettings.Background.GradientPercentage + @") 0%, rgba(0, 0, 0, 0) 100%); 1227 background: linear-gradient(to top, rgba(0, 0, 0, 0." + GeneralSettings.Background.GradientPercentage + @") 0%, rgba(0, 0, 0, 0) 100%); 1228 background-attachment: fixed; 1229 background-color: " + GeneralSettings.Background.Color + @" !important; 1230 }"; 1231 } 1232 1233 if (GeneralSettings.Site.Shadow) 1234 { 1235 CssString += @" 1236 .shad { 1237 -webkit-box-shadow: 0px 0px 8px 0px rgba(50, 50, 50, 0.75); 1238 -moz-box-shadow: 0px 0px 8px 0px rgba(50, 50, 50, 0.75); 1239 box-shadow: 0px 0px 8px 0px rgba(50, 50, 50, 0.75); 1240 }"; 1241 } 1242 1243 //Image settings 1244 if (GeneralSettings.Images.RoundCorners) 1245 { 1246 CssString += @" 1247 .content-image { 1248 border-radius: 6px; 1249 -webkit-border-radius: 6px; 1250 -moz-border-radius: 6px; 1251 }"; 1252 } 1253 1254 //Navbar and header custom settings 1255 if (GeneralSettings.Header.Mode == "cover") 1256 { 1257 CssString += @" 1258 .navbar-wp { 1259 background-color: none !important; 1260 }"; 1261 1262 if (!GeneralSettings.Header.Show || GeneralSettings.Header.Mode == "mobile") 1263 { 1264 CssString += @" 1265 .header-cover .navbar-wp { 1266 top: 0px !important; 1267 }"; 1268 } 1269 } 1270 else 1271 { 1272 if (GeneralSettings.Header.Show) 1273 { 1274 CssString += @" 1275 .navbar-wp.affix .navbar-nav > li > a { 1276 padding: 16px 16px !important; 1277 }"; 1278 } 1279 } 1280 1281 if (GeneralSettings.Header.Background == "colorline") 1282 { 1283 CssString += @" 1284 .first-level, .second-level{ 1285 border-bottom: 1px solid " + ColorSettings.Color.Primary + @" !important; 1286 } 1287 1288 .navbar-wp.affix, .navbar-wp.affix .navbar-nav > li > a { 1289 background-color: #FFF; 1290 color: #333; 1291 } 1292 1293 .navbar-wp.affix .navbar-nav > .active > a, .navbar-wp.affix .navbar-nav > li > a:hover, .navbar-wp.affix .navbar-nav > li > a:focus { 1294 color: " + ColorSettings.Color.NavbarFont + @"; 1295 } 1296 1297 .affix .dw-logotext, .affix .dw-slogantext, .dw-header-sm-title, .dw-offsetmenu-logo { 1298 color: " + GeneralSettings.Logo.SecondaryColor + @" !important; 1299 }"; 1300 } else if (GeneralSettings.Header.Background == "neutral") 1301 { 1302 CssString += @" 1303 .navbar-wp, .navbar-wp.affix, .navbar-wp .navbar-nav > li > a { 1304 background-color: #f1f1f1; 1305 } 1306 1307 .navbar-wp.affix, .navbar-wp.affix .navbar-nav > li > a { 1308 color: #333; 1309 } 1310 1311 .navbar-wp.affix .navbar-nav > .active > a, .navbar-wp.affix .navbar-nav > li > a:hover, .navbar-wp.affix .navbar-nav > li > a:focus { 1312 color: " + ColorSettings.Color.NavbarFont + @"; 1313 } 1314 1315 .affix .dw-logotext, .affix .dw-slogantext, .dw-header-sm-title, .dw-offsetmenu-logo { 1316 color: " + GeneralSettings.Logo.SecondaryColor + @" !important; 1317 }"; 1318 } 1319 else if (GeneralSettings.Header.Background == "transparent") 1320 { 1321 CssString += @" 1322 .navbar-wp, .navbar-wp.affix { 1323 background-color: #FFF; 1324 opacity: 0.9; 1325 filter: alpha(opacity=90); /* For IE8 and earlier */ 1326 } 1327 1328 .navbar-wp.affix, .navbar-wp.affix .navbar-nav > li > a { 1329 color: #333; 1330 } 1331 1332 .navbar-wp.affix .navbar-nav > .active > a, .navbar-wp.affix .navbar-nav > li > a:hover, .navbar-wp.affix .navbar-nav > li > a:focus { 1333 color: " + ColorSettings.Color.NavbarFont + @"; 1334 } 1335 1336 .affix .dw-logotext, .affix .dw-slogantext, .dw-header-sm-title, .dw-offsetmenu-logo { 1337 color: " + GeneralSettings.Logo.SecondaryColor + @" !important; 1338 }"; 1339 } 1340 else 1341 { 1342 CssString += @" 1343 .navbar-wp, .navbar-wp.affix, .navbar-wp .navbar-nav > li > a { 1344 background-color: " + ColorSettings.Color.Secondary + @"; 1345 } 1346 1347 .affix .dw-logotext, .affix .dw-slogantext, .dw-header-sm-title, .dw-offsetmenu-logo { 1348 color: " + GeneralSettings.Logo.SecondaryColor + @" !important; 1349 }"; 1350 } 1351 1352 if (GeneralSettings.Navigation.SelectionMode == "background" || GeneralSettings.Navigation.SelectionMode == "arrow"){ 1353 CssString += NavbarPosition(false, SelectionWeight); 1354 1355 CssString += @" 1356 .dw-navbar-button > a { 1357 background-color: transparent !important; 1358 } 1359 1360 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1361 background-color: " + ColorSettings.Color.Primary + @" !important; 1362 }"; 1363 } 1364 1365 if (GeneralSettings.Navigation.SelectionMode == "underline"){ 1366 CssString += NavbarPosition(true); 1367 1368 CssString += ClearBackground(); 1369 1370 CssString += @" 1371 .dw-navbar-button > a span:after { 1372 position: absolute; 1373 content: ''; 1374 left: 0px; 1375 bottom: 0px; 1376 height: " + SelectionWeight + @"px; 1377 width: 100%; 1378 transform: scaleX(0); 1379 transition: all 0.3s ease-in-out 0s; 1380 } 1381 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1382 color: " + ColorSettings.Color.NavbarFont + @" !important; 1383 } 1384 1385 .dw-navbar-button > a:hover span:after, dw-navbar-button > a:active span:after, dw-navbar-button > a:focus span:after, .active > a span:after { 1386 color: " + ColorSettings.Color.Primary + @" !important; 1387 transform: scaleX(1); 1388 transition: all 0.3s ease-in-out 0s; 1389 }"; 1390 } 1391 1392 if (GeneralSettings.Navigation.SelectionMode == "boxed"){ 1393 CssString += NavbarPosition(true, SelectionWeight); 1394 1395 CssString += @" 1396 .dw-navbar-button > a { 1397 background-color: transparent !important; 1398 } 1399 1400 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1401 background-color: " + ColorSettings.Color.Primary + @" !important; 1402 transition: all 0.3s ease-in-out 0s; 1403 }"; 1404 } 1405 1406 if (GeneralSettings.Navigation.SelectionMode == "border"){ 1407 CssString += NavbarPosition(true, 6, SelectionWeight); 1408 1409 CssString += ClearBackground(); 1410 1411 CssString += @" 1412 .dw-navbar-button > a { 1413 border: " + SelectionWeight + @"px solid transparent !important; transition: None !important; 1414 } 1415 1416 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1417 border-width: " + SelectionWeight + @"px !important; 1418 border-color: " + ColorSettings.Color.Primary + @" !important; 1419 transition: all 0.3s ease-in-out 0s; 1420 }"; 1421 } 1422 1423 if (GeneralSettings.Navigation.SelectionMode == "font"){ 1424 CssString += NavbarPosition(); 1425 1426 CssString += ClearBackground(); 1427 1428 SelectionWeight = (SelectionWeight*100); 1429 1430 CssString += @" 1431 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1432 color: " + ColorSettings.Color.Primary + @" !important; 1433 font-weight: " + SelectionWeight + @" !important; 1434 transition: all 0.3s ease-in-out 0s; 1435 }"; 1436 } 1437 1438 if (GeneralSettings.Navigation.Case){ 1439 CssString += @" 1440 .dw-navbar-button > a { 1441 text-transform: uppercase !important; 1442 }"; 1443 } 1444 else 1445 { 1446 CssString += @" 1447 .dw-navbar-button > a { 1448 text-transform: none !important; 1449 }"; 1450 } 1451 1452 1453 //Breadcrumb custom settings 1454 if (GeneralSettings.Navigation.BreadcrumbMode == "light") 1455 { 1456 CssString += @" 1457 .pg-opt { 1458 border-bottom: 0px; 1459 background: none repeat scroll 0% 0% #FFF; 1460 } 1461 1462 .dw-breadcrumb-title { 1463 font-size: 14px !important; 1464 padding: 5px 0px 5px 0px !important; 1465 } 1466 1467 .dw-breadcrumb { 1468 padding: 10px 0px 10px 0px !important; 1469 }"; 1470 } 1471 1472 if (GeneralSettings.Navigation.BreadcrumbMode == "normal") 1473 { 1474 CssString += @" 1475 .dw-breadcrumb-title { 1476 font-size: 14px !important; 1477 padding: 5px 0px 5px 0px !important; 1478 } 1479 1480 .dw-breadcrumb a, .pg-opt .breadcrumb { 1481 padding: 5px !important; 1482 }"; 1483 } 1484 1485 if (GeneralSettings.Navigation.BreadcrumbMode == "large") 1486 { 1487 CssString += @" 1488 .dw-breadcrumb-title { 1489 font-size: 22px !important; 1490 padding: 15px 0px 15px 0px !important; 1491 } 1492 1493 .dw-breadcrumb { 1494 padding: 15px !important; 1495 }"; 1496 } 1497 1498 1499 if (GeneralSettings.Navigation.BreadcrumbAlign == "right") 1500 { 1501 CssString += @" 1502 .dw-breadcrumb { 1503 float: right !important; 1504 }"; 1505 } 1506 else 1507 { 1508 CssString += @" 1509 .dw-breadcrumb { 1510 float: left !important; 1511 }"; 1512 } 1513 1514 1515 //Left menu custom settings 1516 if (GeneralSettings.Navigation.LeftmenuMode == "light" || GeneralSettings.Navigation.LeftmenuMode == "light-color") 1517 { 1518 CssString += @" 1519 ul.dw-categories, ul.dw-categories > li, ul.dw-categories > li > ul > li { 1520 border: 0px solid #EEE; 1521 } 1522 1523 ul.dw-categories > li > ul { 1524 background: none repeat scroll 0% 0% #FFF; 1525 } 1526 1527 ul.dw-categories li a:hover, ul.dw-categories li a:focus, ul.dw-categories li a:active { 1528 background-color: #FFF !important; 1529 color: " + ColorSettings.Color.Primary + @" !important; 1530 } 1531 ul.dw-categories li a:hover span, ul.dw-categories li a:focus span, ul.dw-categories li a:active span { 1532 1533 color: " + ColorSettings.Color.Primary + @" !important; 1534 } 1535 .list-active, .list-active > a { 1536 background-color: #FFF; 1537 color: " + ColorSettings.Color.Primary + @" !important; 1538 } 1539 .list-active span, .list-active > a span{ 1540 1541 color: " + ColorSettings.Color.Primary + @" !important; 1542 } 1543 .list-open-active { 1544 background-color: #FFF; 1545 color: " + ColorSettings.Color.Primary + @" !important; 1546 }"; 1547 } 1548 1549 if (GeneralSettings.Navigation.LeftmenuMode == "lines") 1550 { 1551 CssString += @" 1552 ul.dw-categories > li { 1553 border-bottom: 1px solid #EEE; 1554 } 1555 1556 ul.dw-categories { 1557 border: 0px solid #EEE; 1558 } 1559 1560 ul.dw-categories > li > ul { 1561 background: none repeat scroll 0% 0% #FFF; 1562 } 1563 1564 ul.dw-categories li a:hover, a:focus, a:active { 1565 background-color: #FFF !important; 1566 color: " + ColorSettings.Color.Primary + @" !important; 1567 } 1568 1569 .list-active, .list-active > a { 1570 background-color: #FFF; 1571 color: " + ColorSettings.Color.Primary + @" !important; 1572 } 1573 1574 .list-open-active { 1575 background-color: #FFF; 1576 color: " + ColorSettings.Color.Primary + @" !important; 1577 }"; 1578 } 1579 1580 if (GeneralSettings.Navigation.LeftmenuMode == "boxed") 1581 { 1582 CssString += @" 1583 ul.dw-categories, ul.dw-categories > li, ul.dw-categories > li > ul > li { 1584 border: 0px solid #EEE; 1585 } 1586 1587 .list-active, .list-active > a { 1588 background-color: " + ColorSettings.Color.Primary + @" !important; 1589 color: #FFF !important; 1590 }"; 1591 } 1592 1593 if (GeneralSettings.Navigation.LeftmenuMode == "border") 1594 { 1595 CssString += @" 1596 ul.dw-categories > li { 1597 border: 1px solid #EEE; 1598 } 1599 1600 ul.dw-categories > li > ul > li { 1601 border-top: 1px solid #EEE; 1602 } 1603 1604 .list-active, .list-active > a { 1605 background-color: " + ColorSettings.Color.Primary + @" !important; 1606 color: #FFF; 1607 }"; 1608 } 1609 1610 if (GeneralSettings.Navigation.LeftmenuMode == "light-color") 1611 { 1612 CssString += @" 1613 ul.dw-categories li a:hover, ul.dw-categories a:focus, ul.dw-categories a:active { 1614 border-left: 6px solid " + ColorSettings.Color.Primary + @"; 1615 } 1616 1617 ul.dw-categories .M2 > li > a:hover, ul.dw-categories .M2 > li > a:focus, ul.dw-categories .M2 > li > a:active, ul.dw-categories .M2 > .list-active > a { 1618 padding-left: 20px; 1619 } 1620 1621 ul.dw-categories .M3 > li > a:hover, ul.dw-categories .M3 > li > a:focus, ul.dw-categories .M3 > li > a:active, ul.dw-categories .M3 > .list-active > a { 1622 padding-left: 30px; 1623 } 1624 1625 ul.dw-categories .M4 > li > a:hover, ul.dw-categories .M4 > li > a:focus, ul.dw-categories .M4 > li > a:active, ul.dw-categories .M4 > .list-active > a { 1626 padding-left: 40px; 1627 } 1628 1629 ul.dw-categories .M5 > li > a:hover, ul.dw-categories .M5 > li > a:focus, ul.dw-categories .M5 > li > a:active, ul.dw-categories .M5 > .list-active > a { 1630 padding-left: 50px; 1631 } 1632 1633 ul.dw-categories .M6 > li > a:hover, ul.dw-categories .M6 > li > a:focus, ul.dw-categories .M6 > li > a:active, ul.dw-categories .M6 > .list-active > a { 1634 padding-left: 50px; 1635 } 1636 1637 ul.dw-categories .M7 > li > a:hover, ul.dw-categories .M7 > li > a:focus, ul.dw-categories .M7 > li > a:active, ul.dw-categories .M7 > .list-active > a { 1638 padding-left: 50px; 1639 } 1640 1641 ul.dw-categories .M8 > li > a:hover, ul.dw-categories .M8 > li > a:focus, ul.dw-categories .M8 > li > a:active, ul.dw-categories .M8 > .list-active > a { 1642 padding-left: 50px; 1643 } 1644 1645 ul.dw-categories .list-active > a { 1646 border-left: 6px solid " + ColorSettings.Color.Primary + @"; 1647 } 1648 1649 .btn-dw:hover, .btn-dw:focus, .btn-dw:active { 1650 1651 }"; 1652 } 1653 1654 1655 //Buttons custom designs 1656 if (GeneralSettings.Navigation.ButtonDesign == "light-rounded") 1657 { 1658 CssString += @" 1659 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart { 1660 border-width: 0px; 1661 } 1662 1663 .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active { 1664 background-color: " + ColorSettings.Color.Primary + @"; 1665 color: #FFF; 1666 border-width: 0px; 1667 opacity: 0.8; 1668 } 1669 1670 .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active { 1671 background-color: " + ColorSettings.Color.Primary + @"; 1672 color: #FFF; 1673 border-width: 0px; 1674 } 1675 1676 .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1677 background-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1678 color: #FFF; 1679 border-width: 0px; 1680 }"; 1681 } 1682 1683 if (GeneralSettings.Navigation.ButtonDesign == "corners") 1684 { 1685 CssString += @" 1686 .btn-dw-primary, .btn-dw-secondary, btn-dw-cart , .btn-dw-cart { 1687 border-radius: 0px !important; 1688 border-width: 0px; 1689 } 1690 1691 .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active { 1692 background-color: " + ColorSettings.Color.Primary + @"; 1693 color: #FFF; 1694 border-width: 0px; 1695 opacity: 0.8; 1696 } 1697 1698 .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active { 1699 background-color: " + ColorSettings.Color.Primary + @"; 1700 color: #FFF; 1701 border-width: 0px; 1702 } 1703 1704 .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1705 background-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1706 color: #FFF; 1707 border-width: 0px; 1708 }"; 1709 } 1710 1711 if (GeneralSettings.Navigation.ButtonDesign == "round") 1712 { 1713 CssString += @" 1714 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart { 1715 padding: 5px 15px; 1716 border-radius: 200px !important; 1717 border-width: 0px !important; 1718 } 1719 1720 .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active { 1721 background-color: " + ColorSettings.Color.Primary + @"; 1722 color: #FFF; 1723 border-width: 0px !important; 1724 opacity: 0.8; 1725 1726 } 1727 1728 .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active { 1729 background-color: " + ColorSettings.Color.Primary + @"; 1730 color: #FFF; 1731 border-width: 0px !important; 1732 } 1733 1734 .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1735 background-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1736 color: #FFF; 1737 border-width: 0px !important; 1738 }"; 1739 } 1740 1741 if (GeneralSettings.Navigation.ButtonDesign == "border") 1742 { 1743 CssString += @" 1744 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart { 1745 background-color: transparent; 1746 } 1747 1748 .btn-dw-primary { 1749 border-width: 4px; 1750 padding: 3px 10px; 1751 color: " + ColorSettings.Color.Primary + @"; 1752 } 1753 1754 .btn-dw-secondary { 1755 border-width: 2px; 1756 color: " + ColorSettings.Color.Secondary + @"; 1757 } 1758 1759 .btn-dw-cart { 1760 border-width: 4px; 1761 padding: 3px 10px; 1762 color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1763 } 1764 1765 .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active { 1766 background-color: " + ColorSettings.Color.Primary + @"; 1767 border-width: 4px; 1768 padding: 3px 10px; 1769 border-color: " + ColorSettings.Color.Primary + @"; 1770 color: #FFF; 1771 } 1772 1773 .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active { 1774 background-color: " + ColorSettings.Color.Primary + @"; 1775 border-width: 2px; 1776 color: #FFF; 1777 border-color: #FFF; 1778 } 1779 1780 .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1781 background-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1782 border-width: 4px; 1783 padding: 3px 10px; 1784 border-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1785 color: #FFF; 1786 }"; 1787 } 1788 1789 if (GeneralSettings.Navigation.ButtonDesign == "border-sharp" || GeneralSettings.Navigation.ButtonDesign == "border-round") 1790 { 1791 CssString += @" 1792 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart { 1793 background-color: transparent; 1794 } 1795 1796 .btn-dw-primary { 1797 border-width: 4px; 1798 padding: 3px 15px; 1799 color: " + ColorSettings.Color.Primary + @"; 1800 } 1801 1802 .btn-dw-secondary { 1803 border-width: 2px; 1804 padding: 5px 15px; 1805 color: " + ColorSettings.Color.Secondary + @"; 1806 } 1807 1808 .btn-dw-cart { 1809 border-width: 4px; 1810 padding: 3px 15px; 1811 color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1812 } 1813 1814 .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active { 1815 background-color: " + ColorSettings.Color.Primary + @"; 1816 border-width: 4px; 1817 color: #FFF; 1818 padding: 3px 15px; 1819 border-color: " + ColorSettings.Color.Primary + @"; 1820 } 1821 1822 .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active { 1823 background-color: " + ColorSettings.Color.Primary + @"; 1824 border-width: 2px; 1825 color: #FFF; 1826 padding: 5px 15px; 1827 border-color: #FFF; 1828 } 1829 1830 .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1831 background-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1832 border-width: 4px; 1833 color: #FFF; 1834 padding: 3px 15px; 1835 border-color: " + GetString("Item.Area.EcommerceCartButtonColor.Color") + @"; 1836 }"; 1837 } 1838 1839 if (GeneralSettings.Navigation.ButtonDesign == "border-sharp") 1840 { 1841 CssString += @" 1842 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart, .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active, .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active, .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1843 border-radius: 0px !important; 1844 }"; 1845 } 1846 1847 if (GeneralSettings.Navigation.ButtonDesign == "border-round") 1848 { 1849 CssString += @" 1850 .btn-dw-primary, .btn-dw-secondary, .btn-dw-cart, .btn-dw-primary:hover, .btn-dw-primary:focus, .btn-dw-primary:active, .btn-dw-secondary:hover, .btn-dw-secondary:focus, .btn-dw-secondary:active, .btn-dw-cart:hover, .btn-dw-cart:focus, .btn-dw-cart:active { 1851 border-radius: 200px !important; 1852 }"; 1853 } 1854 1855 1856 //Headings custom settings 1857 if (GeneralSettings.Headings.Mode == "underline") 1858 { 1859 CssString += @" 1860 .dw-section-title { 1861 border-bottom: 2px solid; 1862 margin-bottom: 15px; 1863 }"; 1864 } 1865 1866 if (GeneralSettings.Headings.Mode == "boxed" || GeneralSettings.Headings.Mode == "boxed-line") 1867 { 1868 CssString += @" 1869 .dw-section-title span { 1870 background-color: " + GetString("Item.Area.HeadingsH1.Color.Color") + @"; 1871 display: inline-block; 1872 padding: 8px 16px; 1873 color: #FFF; 1874 }"; 1875 1876 if (string.IsNullOrWhiteSpace(GetString("Item.Area.HeadingsH1.Color.Color"))) 1877 { 1878 CssString += @" 1879 .dw-section-title { 1880 background-color: " + ColorSettings.Color.Primary + @"; 1881 }"; 1882 } 1883 } 1884 1885 if (GeneralSettings.Headings.Mode == "boxed-line") 1886 { 1887 CssString += @" 1888 .dw-section-title span { 1889 margin-bottom: 2px; 1890 } 1891 1892 .dw-section-title { 1893 border-bottom: 2px solid " + GetString("Item.Area.HeadingsH1.Color.Color") + @"; 1894 margin-bottom: 10px; 1895 }"; 1896 1897 if (string.IsNullOrWhiteSpace(GetString("Item.Area.HeadingsH1.Color.Color"))) 1898 { 1899 CssString += @" 1900 .dw-section-title { 1901 border-bottom: 2px solid " + ColorSettings.Color.Primary + @"; 1902 }"; 1903 } 1904 } 1905 1906 if (GeneralSettings.Headings.Mode == "outline") 1907 { 1908 CssString += @" 1909 .dw-section-title { 1910 color: #FFF; 1911 text-shadow: 1912 -1px -1px 0 " + GetString("Item.Area.HeadingsH1.Color.Color") + @", 1913 1px -1px 0 " + GetString("Item.Area.HeadingsH1.Color.Color") + @", 1914 -1px 1px 0 " + GetString("Item.Area.HeadingsH1.Color.Color") + @", 1915 1px 1px 0 " + GetString("Item.Area.HeadingsH1.Color.Color") + @"; 1916 }"; 1917 1918 if (string.IsNullOrWhiteSpace(GetString("Item.Area.HeadingsH1.Color.Color"))) 1919 { 1920 CssString += @" 1921 .dw-section-title { 1922 text-shadow: 1923 -1px -1px 0 #1A1A1A, 1924 1px -1px 0 #1A1A1A, 1925 -1px 1px 0 #1A1A1A, 1926 1px 1px 0 #1A1A1A; 1927 }"; 1928 } 1929 } 1930 1931 if (GeneralSettings.Headings.Mode == "backline") 1932 { 1933 CssString += @" 1934 .dw-section-title { 1935 font-size: 18px; 1936 text-align: center; 1937 border-bottom: 2px solid; 1938 padding: 0; 1939 margin: 8px 0 20px; 1940 line-height: 0em !important; 1941 } 1942 1943 .dw-section-title > span { 1944 background-color: #FFF; 1945 padding: 0 16px; 1946 } 1947 1948 .dw-section-title-small { 1949 margin: 8px 0 20px; 1950 }"; 1951 } 1952 1953 if (GeneralSettings.Ecommerce.EcomCardDesign == "one") 1954 { 1955 1956 } 1957 1958 if (GeneralSettings.Ecommerce.EcomCardDesign == "two") 1959 { 1960 CssString += @" 1961 .product { 1962 border: 1px solid #E5E5E5; 1963 }"; 1964 } 1965 1966 return CssString; 1967 } 1968 1969 private string ClearBackground() { 1970 string CssString = ""; 1971 1972 CssString += @" 1973 .dw-navbar-button > a { 1974 background-color: rgba(0, 0, 0, 0.0) !important; 1975 } 1976 1977 .dw-navbar-button > a:hover, dw-navbar-button > a:active, dw-navbar-button > a:focus, .active > a { 1978 background-color: rgba(0, 0, 0, 0.0) !important; 1979 }"; 1980 1981 return CssString; 1982 } 1983 1984 private string NavbarPosition(bool margin=false, int specialpadding=6, int extramargin=0) { 1985 int LogoHeight = 0; 1986 string CssString = ""; 1987 int Centerpos = 0; 1988 1989 if (GeneralSettings.Header.Mode != "solid"){ 1990 if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 1991 { 1992 LogoHeight = ImageHeight(); 1993 } 1994 else 1995 { 1996 LogoHeight = GetInteger("Item.Area.LogoFont.Size"); 1997 } 1998 } 1999 else 2000 { 2001 if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2002 { 2003 LogoHeight = 18; 2004 } 2005 else 2006 { 2007 LogoHeight = GetInteger("Item.Area.LogoFont.Size")-10; 2008 } 2009 } 2010 2011 if (margin == false) 2012 { 2013 Centerpos = (LogoHeight/2) + 6; 2014 2015 CssString += @" 2016 .dw-navbar-button > a, .navbar-wp.affix .navbar-nav > li > a { 2017 padding: " + Centerpos + @"px " + (specialpadding+4) + @"px " + Centerpos + @"px " + (specialpadding+4) + @"px !important; 2018 margin: " + extramargin + @"px " + extramargin + @"px !important; 2019 }"; 2020 } 2021 else 2022 { 2023 Centerpos = ((LogoHeight/2)+6)-(specialpadding+extramargin); 2024 2025 CssString += @" 2026 .dw-navbar-button > a, .navbar-wp.affix .navbar-nav > li > a { 2027 padding: " + specialpadding + @"px " + (specialpadding+4) + @"px " + specialpadding + @"px " + (specialpadding+4) + @"px !important; 2028 margin: " + Centerpos + @"px 4px 0px 4px !important; 2029 }"; 2030 } 2031 2032 return CssString; 2033 } 2034 2035 private int ImageHeight () 2036 { 2037 int LogoHeight = 0; 2038 2039 if (!string.IsNullOrWhiteSpace(GetString("Item.Area.GeneralLogo"))) 2040 { 2041 string imageUrl = "http://" + HttpContext.Current.Request.Url.Authority + GetString("Item.Area.GeneralLogo"); 2042 2043 WebRequest request = WebRequest.Create(imageUrl); 2044 WebResponse response = request.GetResponse(); 2045 Image image = Image.FromStream(response.GetResponseStream()); 2046 2047 LogoHeight = image.Height; 2048 } 2049 else 2050 { 2051 LogoHeight = 38; 2052 } 2053 2054 return LogoHeight; 2055 } 2056 } 2057 2058 2059 2060 @{ 2061 InitGeneralSettings(); 2062 } 2063 2064 2065 @if (writeCss) 2066 { 2067 css += FontStylesCSS() + "/*Colors*/" + Environment.NewLine + GetColorSettings() + Environment.NewLine + "/*General*/" + Environment.NewLine + GetGeneralCSS(); 2068 Dynamicweb.Core.Helpers.TextFileHelper.WriteTextFile(css, HttpContext.Current.Server.MapPath("/Files/Templates/Designs/Dwsimple/css/DWGlobalStylesSite" + GetString("DwAreaID") + "_auto.css"), false); 2069 Dynamicweb.Core.Helpers.TextFileHelper.WriteTextFile(RemoveWhiteSpaceFromStylesheets(Dynamicweb.Core.Helpers.TextFileHelper.ReadTextFile(HttpContext.Current.Server.MapPath("/Files/Templates/Designs/Dwsimple/css/DWGlobalStyles.css"))), HttpContext.Current.Server.MapPath("/Files/Templates/Designs/Dwsimple/css/DWGlobalStyles.min.css"), false); 2070 Dynamicweb.Core.Helpers.TextFileHelper.WriteTextFile(RemoveWhiteSpaceFromStylesheets(css), cssPath, false); 2071 } 2072 2073 @functions{ 2074 public static string RemoveWhiteSpaceFromStylesheets(string body) 2075 { 2076 body = Regex.Replace(body, @"[a-zA-Z]+#", "#"); 2077 body = Regex.Replace(body, @"[\n\r]+\s*", string.Empty); 2078 body = Regex.Replace(body, @"\s+", " "); 2079 body = Regex.Replace(body, @"\s?([:,;{}])\s?", "$1"); 2080 body = body.Replace(";}", "}"); 2081 body = Regex.Replace(body, @"([\s:]0)(px|pt|%|em)", "$1"); 2082 // Remove comments from CSS 2083 body = Regex.Replace(body, @"/\*[\d\D]*?\*/", string.Empty); 2084 return body; 2085 } 2086 } 2087 2088 <!-- Template styles --> 2089 <link id="dwStylesheet" type="text/css" href="/Files/Templates/Designs/Catago/css/DWGlobalStyles.min.css" rel="stylesheet" media="screen"> 2090 <link type="text/css" href="/Files/Templates/Designs/Catago/css/styles.min.css" rel="stylesheet"> 2091 2092 @{ string cssAutoPath = "/Files/Templates/Designs/Dwsimple/css/DWGlobalStylesSite" + GetString("DwAreaID") + "_auto.min.css?t=" + areaUpdated.Ticks; } 2093 2094 <link type="text/css" href="@cssAutoPath" rel="stylesheet"> 2095 2096 <!-- Analytics code --> 2097 @GetValue("Item.Area.OtherAnalyticsCode") 2098 <link href="/Files/Templates/Designs/Catago/css/checkbox.css" rel="stylesheet"> 2099 <link href="/Files/Templates/Designs/Catago/css/magic-check.css" rel="stylesheet"> 2100 <link type="text/css" href="/Files/Templates/Designs/Catago/css/style.min.css" rel="stylesheet"> 2101 2102 <script src="/Files/Templates/Designs/Catago/js/jquery-2.1.1.min.js"></script> 2103 @if (GeneralSettings.Navigation.IsMegamenu) 2104 { 2105 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Catago/css/megamenu.css"> 2106 } 2107 <style> 2108 .newsletter-popup--teaser{ 2109 background:@bgbuttonnews; 2110 2111 } 2112 .newsletter-popup--teaser a{ 2113 color:@colorbuttonnews; 2114 } 2115 .newsletter-popup--wrap .newsletter-popup{ 2116 background:@bgwrapnews; 2117 color:@colorwrapnews; 2118 } 2119 .newsletter-popup--wrap .newsletter-popup h2{ 2120 color:@colorwrapnews; 2121 } 2122 .popup-btn{ 2123 background:@bgbtnnbox; 2124 color:@colorbtnnbox; 2125 -webkit-transition: all 0.2s ease-in-out; 2126 -moz-transition: all 0.2s ease-in-out; 2127 -o-transition: all 0.2s ease-in-out; 2128 transition: all 0.2s ease-in-out; 2129 } 2130 .popup-btn:hover{ 2131 color:@bgbtnnbox; 2132 background:@colorbtnnbox; 2133 border:1px solid @bgbtnnbox; 2134 } 2135 </style> 2136 @GetValue("Stylesheets") 2137 @GetValue("Javascripts") 2138 </head> 2139 <body style="@GeneralSettings.Background.Style" id="sitecontent"> 2140 @if (!string.IsNullOrWhiteSpace(GTMID)) 2141 { 2142 <!-- Google Tag Manager (noscript) --> 2143 <noscript> 2144 <iframe src="https://www.googletagmanager.com/ns.html?id=@GTMID" height="0" width="0" style="display:none;visibility:hidden"></iframe> 2145 </noscript> 2146 <!-- End Google Tag Manager (noscript) --> 2147 } 2148 <div id="fb-root"></div> 2149 <script> 2150 (function (d, s, id) { 2151 var js, fjs = d.getElementsByTagName(s)[0]; 2152 if (d.getElementById(id)) return; 2153 js = d.createElement(s); js.id = id; 2154 js.src = "//connect.facebook.net/da_DK/sdk.js#xfbml=1&version=v2.5"; 2155 fjs.parentNode.insertBefore(js, fjs); 2156 }(document, 'script', 'facebook-jssdk')); 2157 </script> 2158 2159 <!-- MODALS --> 2160 <div class="modal fade" id="login" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> 2161 <div class="modal-dialog modal-sm"> 2162 <div class="modal-content"> 2163 <div class="modal-header"> 2164 <h4 class="modal-title" id="myModalLabel">@Translate("Login", "Login")</h4> 2165 </div> 2166 <form role="form" id="loginform" class="form-horizontal" method="post"> 2167 <div class="modal-body"> 2168 <div class="err"></div> 2169 @if (!string.IsNullOrWhiteSpace(GetString("DW_extranet_error_uk"))) 2170 { 2171 <script>alert("@GetValue("DW_extranet_error_uk")");</script> 2172 } 2173 <input type="hidden" name="ID" value="@Pageview.ID"> 2174 <input type="hidden" name="DWExtranetUsernameRemember" value="True"> 2175 <input type="hidden" name="DWExtranetPasswordRemember" value="True"> 2176 <div class="form-group"> 2177 @{ 2178 attrValue = Translate("Enter email", "Enter email"); 2179 var username2 = @GetValue("DWExtranetUsername"); 2180 } 2181 <label for="username" class="control-label">@Translate("Email", "Email")</label> 2182 <input type="text" class="form-control" name="username" id="username" placeholder="@attrValue" value="@username2"> 2183 </div> 2184 <div class="form-group"> 2185 @{ 2186 attrValue = Translate("Enter password", "Enter password"); 2187 } 2188 <label for="password" class="control-label">@Translate("Password", "Password")</label> 2189 <input type="password" class="form-control" name="password" id="password" placeholder="@attrValue"> 2190 </div> 2191 <a class="forgot-pass" href="/Default.aspx?ID=@signInPageId&LoginAction=Recovery">@Translate("Forgot your password?", "Forgot your password?")</a> 2192 </div> 2193 <div class="modal-footer"> 2194 <div class="checkbox pull-left"> 2195 <label> 2196 <input type="checkbox" name="autologin" id="autologin" checked="checked" value="True"> 2197 @Translate("Remember me", "Remember me") 2198 </label> 2199 </div> 2200 <button type="submit" class="btn btn-sm btn-dw-primary pull-right">@Translate("Login", "Login")</button> 2201 </div> 2202 @if (GetLoop("DWExtranetExternalLoginProviders").Count != 0) 2203 { 2204 <div class="modal-footer"> 2205 <div class="text-left">@Translate("Or sign in using", "Or sign in using"):</div> 2206 <ul class="providers"> 2207 @foreach (LoopItem LoginProvider in GetLoop("DWExtranetExternalLoginProviders")) 2208 { 2209 var ProviderName = LoginProvider.GetString("ProviderName").ToLower(); 2210 var ProviderID = LoginProvider.GetValue("ProviderID"); 2211 <li><a href='/Admin/Public/Social/ExternalLogin.aspx?action=login&amp;providerID=@ProviderID' class="btn btn-xs btn-dw-primary pull-left"><i class="fa fa-@ProviderName"></i>&nbsp;@LoginProvider.GetString("ProviderName")</a></li> 2212 } 2213 </ul> 2214 </div> 2215 } 2216 </form> 2217 </div> 2218 </div> 2219 </div> 2220 2221 <!-- MOBILE MENU --> 2222 @{ 2223 var offsetmenuplace = "left"; 2224 2225 if (GeneralSettings.Header.Mode == "mobile") 2226 { 2227 offsetmenuplace = GeneralSettings.Navigation.Position; 2228 } 2229 } 2230 2231 @if ((Pageview.Device.ToString() == "Mobile") || (Pageview.Device.ToString() == "Tablet")) 2232 { 2233 <div id="myNavmenu" class="navmenu navmenu-default navmenu-fixed-@offsetmenuplace offcanvas"> 2234 <div class="col-sm-12 col-xs-12 offcanvas-col"> 2235 <div class="row offcanvas-row">&nbsp;</div> 2236 <div class="row offcanvas-row"> 2237 <div class="col-sm-12 col-xs-12 offcanvas-col"> 2238 <a href="/Default.aspx?ID=@firstpageid" class="brand"> 2239 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2240 { 2241 <div class="img-responsive dw-offsetmenu-logo pull-left"> 2242 @if (GeneralSettings.Logo.ContrastImage != GeneralSettings.Logo.Image) 2243 { 2244 <img src="@GeneralSettings.Logo.ContrastImage" alt="Logo"> 2245 } 2246 else 2247 { 2248 <img class="img-responsive" src="@GeneralSettings.Logo.Image" alt="Logo"> 2249 } 2250 </div> 2251 } 2252 2253 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Text)) 2254 { 2255 <div class="dw-logotext dw-offsetmenu-logo pull-left">@GeneralSettings.Logo.Text</div> 2256 } 2257 </a> 2258 2259 <div class="closeBtn btn btn-sm btn-base" data-toggle="offcanvas" data-target="#myNavmenu" data-canvas="body"> 2260 <i class="fa fa-times"></i> 2261 </div> 2262 </div> 2263 </div> 2264 <div class="row offcanvas-row">&nbsp;</div> 2265 </div> 2266 2267 <div class="col-sm-12 col-xs-12 offcanvas-col"> 2268 @if (GetBoolean("Item.Area.EcomEnabled")) 2269 { 2270 <div class="row offcanvas-row"> 2271 <div class="col-sm-12 col-xs-12 offcanvas-col"> 2272 <form method="get" action="Default.aspx"> 2273 <input type="hidden" name="ID" value='@Pageview.Area.Item["ProductsPageId"]'> 2274 <div class="input-group"> 2275 <input type="text" class="form-control typeahead-products" name="Search" tabindex="1" placeholder="Søg"> 2276 <span class="input-group-btn"> 2277 <button class="btn btn-primary" type="submit"><i class="fa fa-search"></i></button> 2278 </span> 2279 </div> 2280 </form> 2281 </div> 2282 </div> 2283 <div class="user-sm-block"> 2284 <ul class="top-menu"> 2285 @foreach (var lang in GetLoop("WebsiteLanguages")) 2286 { 2287 <li id='@lang.GetValue("ID")area'> 2288 @{ 2289 string langCode = "flag-icon" + lang.GetString("Culture").Substring(2, 3).ToLower(); 2290 <a href='Default.aspx?ID=@lang.GetValue("FirstActivePageID")'><span class="flag-icon @langCode"></span></a> 2291 } 2292 </li> 2293 } 2294 </ul> 2295 </div> 2296 } 2297 </div> 2298 <div class="row offcanvas-row"> 2299 <div class="col-sm-12 col-xs-12 offcanvas-col"> 2300 @if (Dynamicweb.Frontend.PageView.Current().Device == Dynamicweb.Frontend.Devices.DeviceType.Mobile || Dynamicweb.Frontend.PageView.Current().Device == Dynamicweb.Frontend.Devices.DeviceType.Tablet) 2301 { 2302 2303 <text> 2304 @RenderNavigation(new { StartLevel = 1, EndLevel = 6, Template = "MobileNavigation.xslt", ExpandMode = "All" }) 2305 </text> 2306 2307 } 2308 2309 2310 </div> 2311 </div> 2312 </div> 2313 } 2314 2315 <!-- HEADER AND CONTENT--> 2316 2317 <div class="body-wrap shad @GeneralSettings.Site.LayoutMode"> 2318 2319 <!-- HEADER --> 2320 <div id="divHeaderWrapper"> 2321 <header class="@GeneralSettings.Header.Classes"> 2322 2323 <!-- TOP HEADER --> 2324 @if (GeneralSettings.Header.Show) 2325 { 2326 <div class="top-header"> 2327 <div class="top-header-service"> 2328 <div class="container logobox"> 2329 <div class="social-icons-top"> 2330 @if (GetBoolean("Item.Area.SocialLinksInFooter")) 2331 { 2332 string sicon = ""; 2333 string slink = ""; 2334 <div class="pull-left"> 2335 <div class="col"> 2336 @foreach (LoopItem socialitem in GetLoop("Item.Area.SocialList")) 2337 { 2338 sicon = socialitem.GetString("Item.Area.SocialList.Icon"); 2339 slink = socialitem.GetString("Item.Area.SocialList.Link"); 2340 <a href="@slink" target="blank"><i class="fa @sicon fa-2x"></i>&nbsp;&nbsp;</a> 2341 } 2342 </div> 2343 </div> 2344 } 2345 </div> 2346 <nav class="top-header-menu hidden-sm hidden-xs"> 2347 <ul class="top-menu"> 2348 @foreach (var lang in GetLoop("WebsiteLanguages")) 2349 { 2350 2351 if (lang.GetInteger("ID") != 5) 2352 { 2353 <li id='@lang.GetValue("ID")area' class="lang-menu"> 2354 @{ 2355 string langCode = "flag-icon" + lang.GetString("Culture").Substring(2, 3).ToLower(); 2356 <a href='Default.aspx?ID=@lang.GetValue("FirstActivePageID")'><span class="flag-icon @langCode"></span></a> 2357 } 2358 2359 </li> 2360 } 2361 } 2362 2363 <!-- Ecommerce user menu --> 2364 @if (GetBoolean("Item.Area.EcomEnabled")) 2365 { 2366 2367 <text> 2368 @GetValue("DwNavigation(servicenavigation)") 2369 </text> 2370 2371 } 2372 </ul> 2373 </nav> 2374 </div> 2375 </div> 2376 <div class="container"> 2377 <div class="row"> 2378 <!-- Small screen header --> 2379 2380 <div class="hidden-lg hidden-md mobileFixMenu"> 2381 <div class="dw-header-sm"> 2382 <div class="pull-left"> 2383 <button type="button" class=" btn btn-lg btn-base" data-toggle="offcanvas" data-target="#myNavmenu" data-canvas="body"> 2384 <i class="fa fa-bars"></i> 2385 </button> 2386 &nbsp;&nbsp;&nbsp; 2387 </div> 2388 2389 <div class="pull-left hidden-xs"> 2390 <h2 class="dw-header-sm-title">@GetGlobalValue("Global:Page.Top.Name")</h2> 2391 </div> 2392 2393 </div> 2394 </div> 2395 2396 <div class="col-sm-4 logobox hidden-lg hidden-md mobileFixLogo"> 2397 @if (GeneralSettings.Header.Mode == "solid") 2398 { 2399 <a href="/Default.aspx?ID=@firstpageid" class="brand"> 2400 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2401 { 2402 <img class="img-responsive dw-logoimage pull-left" src="@GeneralSettings.Logo.Image" alt="Logo"> 2403 } 2404 2405 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Text)) 2406 { 2407 <div class="dw-logotext pull-left">@GeneralSettings.Logo.Text</div> 2408 } 2409 </a> 2410 2411 if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Slogan)) 2412 { 2413 <div class="dw-slogantext pull-left">@GeneralSettings.Logo.Slogan</div> 2414 } 2415 } 2416 </div> 2417 </div> 2418 </div> 2419 2420 2421 </div> 2422 } 2423 2424 <!-- MAIN NAV --> 2425 @{ 2426 var sticky = GeneralSettings.Navigation.StickyMenu; 2427 var stickyTrigger = "affix"; 2428 var navbarpos = GeneralSettings.Navigation.Position; 2429 var selectionstyle = GeneralSettings.Navigation.SelectionStyle; 2430 2431 if (sticky == "off") 2432 { 2433 stickyTrigger = ""; 2434 } 2435 } 2436 2437 <div id="navOne" class="navbar navbar-wp @selectionstyle navbar-fixed affix-top" role="navigation" data-spy="@stickyTrigger" data-offset-top="@sticky" data-offset-bottom="300"> 2438 <div class=""> 2439 @if (GeneralSettings.Header.Mode != "solid" || !GeneralSettings.Header.Show) 2440 { 2441 <div class="navbar-header"> 2442 <div> 2443 <a href="/Default.aspx?ID=@firstpageid" class="brand"> 2444 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2445 { 2446 if (GeneralSettings.Logo.ContrastImage != GeneralSettings.Logo.Image) 2447 { 2448 <img class="img-responsive dw-logoimage dw-logoimage-normal pull-left" src="@GeneralSettings.Logo.Image" alt="Logo"> 2449 <img class="img-responsive dw-logoimage dw-logoimage-contrast pull-left" src="@GeneralSettings.Logo.ContrastImage" alt="Logo"> 2450 } 2451 else 2452 { 2453 <img class="img-responsive dw-logoimage pull-left" src="@GeneralSettings.Logo.Image" alt="Logo"> 2454 } 2455 } 2456 2457 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Text)) 2458 { 2459 <div class="dw-logotext pull-left">@GeneralSettings.Logo.Text</div> 2460 } 2461 </a> 2462 2463 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Slogan)) 2464 { 2465 <div class="dw-slogantext pull-left">@GeneralSettings.Logo.Slogan</div> 2466 } 2467 </div> 2468 </div> 2469 } 2470 2471 <!-- Big screen header --> 2472 <div class="navbar-navigation "> 2473 2474 <nav class="col-md-12 col-sm-12 col-xs-12 p-0 navbar-@navbarpos"> 2475 @if (GeneralSettings.Navigation.IsMegamenu) 2476 { 2477 <div class="row first-level hidden-sm hidden-xs"> 2478 2479 2480 <div class="container"> 2481 <div class="col-md-4 logobox hidden-xs hidden-sm"> 2482 @if (GeneralSettings.Header.Mode == "solid") 2483 { 2484 <a href="/Default.aspx?ID=@firstpageid" class="brand"> 2485 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2486 { 2487 <img class="img-responsive dw-logoimage pull-left" src="@GeneralSettings.Logo.Image" alt="Logo"> 2488 } 2489 2490 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Text)) 2491 { 2492 <div class="dw-logotext pull-left">@GeneralSettings.Logo.Text</div> 2493 } 2494 </a> 2495 2496 if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Slogan)) 2497 { 2498 <div class="dw-slogantext pull-left">@GeneralSettings.Logo.Slogan</div> 2499 } 2500 } 2501 </div> 2502 @GetValue("DwNavigation(topnavigationtop)") 2503 <!-- Ecommerce user menu --> 2504 <ul class="icons-wrapper"> 2505 @if (GetBoolean("Item.Area.EcomEnabled")) 2506 { 2507 if (GeneralSettings.Header.Mode == "solid" && GeneralSettings.Header.Show) 2508 { 2509 <li class="hidden-sm hidden-xs"> 2510 2511 <ul class=" search-dropdown pull-right"> 2512 <li> 2513 <form method="get" action="Default.aspx"> 2514 <input type="hidden" name="ID" value='@searchpage'> 2515 <div class="input-group pull-@GeneralSettings.Navigation.InvertedPosition dw-top-search"> 2516 <input type="text" class="form-control typeahead-products" name="search" tabindex="1" placeholder="@searchplaceholder"> 2517 <span class="input-group-btn"> 2518 <button class="btn btn-primary btn-search" type="submit"><i class="fa fa-search"></i></button> 2519 </span> 2520 </div> 2521 </form> 2522 </li> 2523 </ul> 2524 </li> 2525 } 2526 2527 } 2528 </ul> 2529 </div> 2530 2531 </div> 2532 @GetValue("DwNavigation(topnavigationmegamenu)") 2533 2534 2535 } 2536 else 2537 { 2538 @GetValue("DwNavigation(topnavigation)") 2539 } 2540 2541 <!-- Extra navigation when no header is shown --> 2542 @if (GetBoolean("Item.Area.EcomEnabled")) 2543 { 2544 if (!GeneralSettings.Header.Show) 2545 { 2546 <ul class="nav navbar-nav"> 2547 <li>&nbsp;&nbsp;&nbsp;</li> 2548 @if (!Dynamicweb.Core.Converter.ToBoolean(GetGlobalValue("Global:Extranet.UserName"))) 2549 { 2550 <li class="dw-navbar-button"><a href="#" data-toggle="modal" data-target="#login" data-hover="dropdown"><i class="fa fa-sign-in"></i><span></span></a></li> 2551 <li class="dw-navbar-button"><a href="/not-logged-in/create-user-profile" data-hover="dropdown"><i class="fa fa-user"></i><span></span></a></li> 2552 } 2553 2554 @if (Dynamicweb.Core.Converter.ToBoolean(GetGlobalValue("Global:Extranet.UserName"))) 2555 { 2556 <li class="dw-navbar-button"> 2557 <a href='Default.aspx?ID=@Pageview.Area.Item["OrdersPageId"]' data-hover="dropdown"> 2558 <nobr> 2559 <strong><i class="fa fa-user"></i></strong> 2560 </nobr> 2561 <span></span> 2562 </a> 2563 </li> 2564 <li class="dw-navbar-button"> 2565 <a href="/Admin/Public/ExtranetLogoff.aspx?ID=@Pageview.Page.ID" data-hover="dropdown"><i class="fa fa-sign-out"></i><span></span></a> 2566 </li> 2567 } 2568 2569 <li class="dw-navbar-button"> 2570 <a href="Default.aspx?ID=@cartid" title="" id="minipagecart-extra" data-hover="dropdown"><i class="fa fa-shopping-cart"></i> @GetValue("Ecom:Order.OrderLines.TotalProductQuantity") <span class="amount">@GetValue("Ecom:Order.OrderLines.Total.PriceWithVAT")</span><span></span></a> 2571 </li> 2572 </ul> 2573 } 2574 2575 if (GeneralSettings.Header.Mode != "solid") 2576 { 2577 <ul class="nav navbar-nav"> 2578 <li class="dropdown dropdown-aux animate-click dw-navbar-button" data-animate-in="animated bounceInUp" data-animate-out="animated fadeOutDown" style="z-index:500;"> 2579 <a href="#" class="dropdown-toggle" data-toggle="dropdown" data-hover="dropdown"><i class="fa fa-search"></i><span></span></a> 2580 <ul class="dropdown-menu dropdown-menu-user animate-wr"> 2581 <li id="dropdownForm"> 2582 <div class="dropdown-form"> 2583 <form class="form-light p-15" role="form" method="get" action="Default.aspx"> 2584 <input type="hidden" name="ID" value='@searchpage'> 2585 <div class="input-group"> 2586 <input type="text" class="form-control typeahead-products" name="search" placeholder="@searchplaceholder"> 2587 <span class="input-group-btn"> 2588 <button class="btn btn-base" type="submit"><i class="fa fa-search"></i></button> 2589 </span> 2590 </div> 2591 </form> 2592 </div> 2593 </li> 2594 </ul> 2595 </li> 2596 </ul> 2597 } 2598 } 2599 </nav> 2600 </div> 2601 2602 2603 </div> 2604 </div> 2605 2606 @if (!string.IsNullOrWhiteSpace(GetString("Item.Area.HeaderLayoutImage"))) 2607 { 2608 if (currentpageid != firstpageid) 2609 { 2610 var coverimage = GetString("Item.Area.HeaderLayoutImage"); 2611 2612 <div class="container-fluid dw-header-image"> 2613 <div class="row"> 2614 <section class="carousel carousel-1 slice fluid" style="height: 160px !important; background: url('/Admin/Public/Getimage.ashx?width=1920&amp;compression=75&amp;Crop=5&amp;image=@coverimage') no-repeat; background-size: cover !important; background-color: @ColorSettings.Color.Secondary"></section> 2615 </div> 2616 </div> 2617 } 2618 else if (GeneralSettings.Header.ShowFrontpageImage) 2619 { 2620 var coverimage = GetString("Item.Area.HeaderLayoutImage"); 2621 2622 <div class="container-fluid dw-header-image"> 2623 <div class="row"> 2624 <section class="carousel carousel-1 slice fluid" style="height: 160px !important; background: url('/Admin/Public/Getimage.ashx?width=1920&amp;compression=75&amp;Crop=5&amp;image=@coverimage') no-repeat; background-size: cover !important; background-color: @ColorSettings.Color.Secondary"></section> 2625 </div> 2626 </div> 2627 } 2628 } 2629 else if (GeneralSettings.Header.Mode != "solid") 2630 { 2631 if (currentpageid != firstpageid) 2632 { 2633 <div class="container-fluid dw-header-image"> 2634 <div class="row"> 2635 <section class="carousel carousel-1 slice fluid" style="height: 160px !important; background-color: transparent; background-size: cover !important;"></section> 2636 </div> 2637 </div> 2638 } 2639 } 2640 2641 @if (Dynamicweb.Core.Converter.ToBoolean(GetGlobalValue("Global:Extranet.UserName")) && GetLoop("DWExtranetSecondaryUsers").Count > 0) 2642 { 2643 var active = ""; 2644 if (!string.IsNullOrWhiteSpace(GetGlobalValue("Global:Extranet.SecondaryUser.UserID")) && GetString("DwPageID") != GetString("DwAreaFirstActivePageID")) 2645 { 2646 active = "active-impersonating"; 2647 } 2648 <div class="impersonation-panel @active"> 2649 @*Impersonation*@ 2650 <div class="container"> 2651 @if (!string.IsNullOrWhiteSpace(GetGlobalValue("Global:Extranet.SecondaryUser.UserID")) && GetString("DwPageID") != GetString("DwAreaFirstActivePageID")) 2652 { 2653 string stopImpersonateTranslation = Translate("Stop impersonation", "Stop impersonation"); 2654 <i class="fa fa-user-secret"></i> 2655 @GetGlobalValue("Global:Extranet.SecondaryUser.UserName")<text>&nbsp;</text>@Translate("is impersonated by")<<<text>&nbsp;</text>@Pageview.User.UserName 2656 <form method="post"> 2657 <input type="submit" class="btn btn-default" name="DwExtranetRemoveSecondaryUser" value="@stopImpersonateTranslation"> 2658 </form> 2659 } 2660 else 2661 { 2662 <a href="/Default.aspx?ID=@ImpersonationPageId" title="View the list of users you can impersonate"><i class="fa fa-user-secret"></i>@Translate("View the list of users you can impersonate", "View the list of users you can impersonate")</a> 2663 } 2664 </div> 2665 </div> 2666 } 2667 </header> 2668 </div> 2669 2670 <!-- MAIN CONTENT --> 2671 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 2672 2673 2674 @GetValue("Title(Full width page)") 2675 @GetValue("Description(Use this page for full width pages with no left navigation.)") 2676 @{ 2677 string siteurl = GetGlobalValue("Global:Request.Url").ToString(); 2678 string userGroup = "0"; 2679 } 2680 @SnippetStart("PrimaryColor")@GetString("Item.Area.ColorsPrimary.Color")@SnippetEnd("PrimaryColor") 2681 <div class="userid hidden">@GetGlobalValue("Global:Extranet.UserID")</div> 2682 @if (GetLoop("DWExtranetSecondaryUsers").Count > 0) 2683 { 2684 <div class="check-user hidden">1</div> 2685 } 2686 else{ 2687 <div class="check-user hidden">0</div> 2688 } 2689 @if (GetString("DW_extranet_Groups").Contains("6828")) 2690 { 2691 userGroup = "pets"; 2692 } 2693 @if (GetString("DW_extranet_Groups").Contains("6829")) 2694 { 2695 userGroup = "riding"; 2696 } 2697 @if (GetString("DW_extranet_Groups").Contains("6830")) 2698 { 2699 userGroup = "petRiding"; 2700 } 2701 <div class="userGroup hidden">@userGroup</div> 2702 @if(GetBoolean("Item.Page.LayoutShowBreadcrumb")){ 2703 <div class="pg-opt pin white"> 2704 <div class="container"> 2705 <div class=""> 2706 @if (!GetBoolean("Item.Page.LayoutHideLeftMenu")){ 2707 <div class="col-lg-3 col-md-3 hidden-sm hidden-xs"> 2708 @if (GeneralSettings.Navigation.BreadcrumbMode != "light") 2709 { 2710 <div class="dw-breadcrumb-title">@GetGlobalValue("Global:Page.Top.Name")</div> 2711 } 2712 </div> 2713 } 2714 <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12"> 2715 @GetValue("DwNavigation(breadcrumb)") 2716 </div> 2717 </div> 2718 </div> 2719 </div> 2720 } 2721 2722 <section class="slice white animate-hover-slide"> 2723 <div class="container"> 2724 2725 <div class="row"> 2726 @if (!GetBoolean("Item.Page.LayoutHideLeftMenu")) 2727 { 2728 <div class="col-md-3 hidden-sm hidden-xs"> 2729 <div class="widget"> 2730 <h3 class="dw-section-title dw-section-title-small"><span>@GetGlobalValue("Global:Page.Top.Name")</span></h3> 2731 &nbsp; 2732 @GetValue("DwNavigation(leftnavigation)") 2733 </div> 2734 <p>&nbsp;</p> 2735 </div> 2736 } 2737 2738 @*The content*@ 2739 @{ 2740 var attributeValue = "col-md-9 col-sm-12 col-xs-12"; 2741 2742 if (GetBoolean("Item.Page.LayoutHideLeftMenu")) 2743 { 2744 attributeValue = "col-md-12 col-sm-12 col-xm-12"; 2745 } 2746 } 2747 2748 <div class="@attributeValue"> 2749 <div class="row" id="maincontent">@GetValue("DwContent(maincontent)")</div> 2750 </div> 2751 2752 @*Facebook like button*@ 2753 @if (GetBoolean("Item.Page.FacebookLikeButton")) 2754 { 2755 <div class="container"> 2756 <div class="col-md-12 col-sm-12 col-xs-12"> 2757 <div class="row"> 2758 <iframe src="//www.facebook.com/plugins/like.php?href=@siteurl&amp;width=200&amp;layout=button_count&amp;action=recommend&amp;show_faces=true&amp;share=true&amp;height=21" style="border:none; overflow:hidden; height:21px;"></iframe> 2759 </div> 2760 </div> 2761 </div> 2762 } 2763 </div> 2764 </div> 2765 </section> 2766 2767 2768 2769 2770 <!-- FOOTER --> 2771 2772 <div class="body-wrap @GeneralSettings.Site.LayoutMode"> 2773 <footer class="footer"> 2774 <div class="container"> 2775 <div class="row"> 2776 @if (GetBoolean("Item.Area.FooterShowContactInfo")) 2777 { 2778 <div class="col-md-4 col-sm-6 col-xs-12"> 2779 <div class="col"> 2780 <h4>@Translate("Contact us", "Contact us")</h4> 2781 2782 @{ 2783 string footeremail = GetString("Item.Area.FooterEmail"); 2784 string footerphone = GetString("Item.Area.FooterPhone").Replace(" ", ""); 2785 } 2786 2787 <ul> 2788 <li>@GetValue("Item.Area.FooterCompanyName")</li> 2789 <li>@GetValue("Item.Area.FooterAddress")</li> 2790 <li>@Translate("Phone", "Phone"): <a href="tel:@footerphone">@footerphone</a></li> 2791 <li>@Translate("Email", "Email"): <a href="mailto:@footeremail" title="Email Us">@GetValue("Item.Area.FooterEmail")</a></li> 2792 </ul> 2793 <div>&nbsp;</div> 2794 </div> 2795 </div> 2796 } 2797 2798 @if (GetBoolean("Item.Area.FooterNewsletterSignUp")) 2799 { 2800 <div class="col-md-3 col-sm-6 col-xs-12"> 2801 <div class="col"> 2802 <h4>@Translate("Mailing list", "Mailing list")</h4> 2803 <p>@Translate("Sign up if you would like to receive occasional treats from us", "Sign up if you would like to receive occasional treats from us").</p> 2804 <form name="UserManagementEditForm" action="/Default.aspx?ID=@signUpPageId" method="POST" enctype="multipart/form-data"> 2805 <input name="UserManagementForm" value="1" type="hidden"> 2806 <input id="UserManagementForm.DeleteImage" name="UserManagementForm.DeleteImage" type="hidden"> 2807 <div style="display: none;"> 2808 <input name="UserManagement_Form_EmailAllowed" id="UserManagement_Form_EmailAllowed" value="True" checked="checked" type="checkbox"> 2809 <input name="UserManagement_Form_EmailAllowed_ApplyValue" id="UserManagement_Form_EmailAllowed_ApplyValue" value="AllowEmail" type="hidden"> 2810 </div> 2811 <div class="input-group"> 2812 @{ attrValue = Translate("Your email address", "Your email address");} 2813 2814 <input name="UserManagement_Form_Email" id="UserManagement_Form_Email" type="email" class="form-control" placeholder="@attrValue" required="required"> 2815 <span class="input-group-btn"> 2816 <input class="btn btn-base" type="submit" id="submitter" value="Go"> 2817 </span> 2818 </div> 2819 <div>&nbsp;</div> 2820 </form> 2821 </div> 2822 </div> 2823 2824 } 2825 2826 2827 <div class="col-md-4 col-sm-6 col-xs-12"> 2828 <div class="col"> 2829 <h4>@Translate("Social links", "Social links")</h4> 2830 <p> 2831 <!--Hardcoded because of bad performance in Social List--> 2832 <span> 2833 <a href="https://www.facebook.com/catagoequestrian/" target="_blank"><i class="fa fa-facebook-square fa-2x"></i>&nbsp;&nbsp;</a> 2834 </span> 2835 <span> 2836 <a href="https://www.instagram.com/catago_equestrian/" target="_blank"><i class="fa fa-instagram fa-2x"></i>&nbsp;&nbsp;</a> 2837 </span> 2838 </p> 2839 </div> 2840 </div> 2841 2842 @if (GetBoolean("Item.Area.FooterShowSitemap")) 2843 { 2844 <div class="col-md-6 col-sm-12 col-xs-12"> 2845 <div class="col"> 2846 @GetValue("DwNavigation(footersitemap)") 2847 </div> 2848 <div>&nbsp;</div> 2849 </div> 2850 } 2851 </div> 2852 2853 <hr> 2854 <div class="row"> 2855 <div class="col-lg-10 col-md-9 col-sm-9 col-xs-9 copyright"> 2856 <div class="col"> 2857 <p>@GetGlobalValue("Global:Server.Date.Year") &copy; @GetValue("Item.Area.FooterCompanyName"). @Translate("All rights reserved.", "All rights reserved.")</p> 2858 </div> 2859 </div> 2860 @if (GetString("Item.Area.WebmasterLinkCode") != "") 2861 { 2862 <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3"> 2863 <div class="col pull-right"> 2864 @{ 2865 var webmasterlink = GetString("Item.Area.WebmasterLinkCode"); 2866 var username = GetValue("Item.Area.FooterEmail"); 2867 var pagename = GetGlobalValue("Global:Page.Name"); 2868 } 2869 2870 <p><a href="javascript:void(0);" rel="nofollow" onclick="window.open('@webmasterlink?un=@username&amp;pn=@pagename&amp;url=' + encodeURI(location),'_blank','width=1050,height=750,resizable=yes,scrollbars=yes');">Webmaster</a></p> 2871 </div> 2872 </div> 2873 } 2874 <div class="col-md-2 col-sm-6 col-xs-12"> 2875 <div class="col"> 2876 @if (GeneralSettings.Header.Mode == "solid") 2877 { 2878 <a href="/Default.aspx?ID=@firstpageid" class="brand"> 2879 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Image)) 2880 { 2881 <img class="img-responsive pull-left" src="@GeneralSettings.Logo.Image" alt="Logo"> 2882 } 2883 2884 @if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Text)) 2885 { 2886 <div class="dw-logotext pull-left">@GeneralSettings.Logo.Text</div> 2887 } 2888 </a> 2889 2890 if (!string.IsNullOrWhiteSpace(GeneralSettings.Logo.Slogan)) 2891 { 2892 <div class="dw-slogantext pull-left">@GeneralSettings.Logo.Slogan</div> 2893 } 2894 } 2895 </div> 2896 </div> 2897 </div> 2898 </div> 2899 </footer> 2900 </div> 2901 </div> 2902 @if (!hideWishList) 2903 { 2904 <div class="wishlist-wrapper"> 2905 <div id="wistlist-btn"><span>@Translate("Wish list", "Wish list")</span><i class="fa fa-heart-o"></i><span class="cart-quantity"> </span></div> 2906 <div class="wishlist-container hidden"> 2907 <ul class="sub-menu flickerFix"> 2908 <li id="minicart"> 2909 @MiniCart() 2910 </li> 2911 <li class="viewmore"> 2912 <button type="button" class="btn btn-primary">@Translate("View more", "View more")</button> 2913 </li> 2914 <li class="clearall"> 2915 <button class="btn btn-primary" onclick="EmptyCartFav();">@Translate("Remove all", "Remove all")</button> 2916 </li> 2917 <li class="sendform"> 2918 <button type="button" class="btn btn-primary" data-toggle="modal" data-target="#sendform">@Translate("Send", "Send")</button> 2919 </li> 2920 2921 </ul> 2922 2923 </div> 2924 </div> 2925 } 2926 <div class="" id="viewmore"> 2927 <div class="clearfix"> 2928 <i class="fa fa-times viewmore-close pull-left" aria-hidden="true"></i> 2929 <button class="btn btn-default pull-right" onclick="EmptyCartFav();">@Translate("Clear all", "Clear all")</button> 2930 <button class="btn btn-default pull-right" id="edit">@Translate("Edit", "Edit")</button> 2931 <button class="btn btn-default pull-right hidden" id="done">@Translate("Done", "Done")</button> 2932 </div> 2933 <div>&nbsp;</div> 2934 <div class="form-title text-center"> 2935 <i class="fa fa-heart-o t"></i> 2936 <div class="cart-wrapper"> 2937 <div class=" fav-list"> 2938 <div class="row"> 2939 <span class="title-fav">@Translate("Favorite list", "Favorite list")</span><span id="count-pro"></span> 2940 </div> 2941 <hr> 2942 <div class="row list" id="FavList"> 2943 </div> 2944 </div> 2945 </div> 2946 </div> 2947 </div> 2948 <script type="text/html-template" id="FavAjaxTemplate"> 2949 <div class="productlist boxes"> 2950 <div class="boxproduct wp-block product"> 2951 <div class="overview"> 2952 2953 <div class="product-container"> 2954 2955 <div class="product-favorites pull-right"> 2956 <input type="number" name="Quantity" value="1" class="hidden quantity"> 2957 2958 <a onclick='RemoveToCartFav(event,"Obj.id","Obj.variantid")' class="orderline-remove hidden" title="@Translate(" Remove", "Remove" )"><i class="fa fa-trash" aria-hidden="true"></i></a> 2959 2960 </div> 2961 2962 <div class="new-icon pull-right "> 2963 2964 <img src="/files/templates/designs/dwsimple/images/icons/new.png" alt="" class="Obj.hiddendate" /> 2965 2966 </div> 2967 2968 <div class="listproductright"> 2969 <div class="row gallery-container"> 2970 <a href="Obj.link" class="link-name" data-deflink="Obj.link"> 2971 <div class="right-col large-image pull-right"> 2972 <img alt="Obj.name" data-src="/Admin/Public/Getimage.ashx?width=300&amp;height=300&amp;compression=85&amp;Crop=5&amp;image=Obj.image" src="/Admin/Public/Getimage.ashx?width=300&amp;height=300&amp;compression=85&amp;Crop=5&amp;image=Obj.image" class="img-responsive largeImage img-center"> 2973 </div> 2974 </a> 2975 </div> 2976 2977 </div> 2978 <div class="listproductinfo"> 2979 <div class="extracolumn"> 2980 <div style="" class="longproductdescription"> 2981 <a href="Obj.link" class="link-name" data-deflink="Obj.link"> 2982 <p class="text-center" data-defname="Obj.shortname">Obj.shortname</p> 2983 </a> 2984 </div> 2985 2986 </div> 2987 </div> 2988 </div> 2989 </div> 2990 2991 </div> 2992 </div> 2993 </script> <!-- Modal --> 2994 <div class="modal fade" id="sendform" tabindex="-1" role="dialog" aria-labelledby="sendform" aria-hidden="true"> 2995 <div class="modal-dialog" role="document"> 2996 <div class="modal-content"> 2997 <div class="modal-header"> 2998 <strong>@Translate("Send list", "Send list")</strong> 2999 <button type="button" class="close" data-dismiss="modal" aria-label="Close"> 3000 <span aria-hidden="true">&times;</span> 3001 </button> 3002 </div> 3003 3004 <div class="modal-body send-form"> 3005 <!--@Global:Paragraph.Content(@GetInteger("Item.Area.WishListSendFormParagraphId"))--> 3006 </div> 3007 <div class="modal-body confirm-message hidden"> 3008 3009 </div> 3010 </div> 3011 </div> 3012 </div> 3013 3014 3015 @if (GetBoolean("Item.Area.ShowNewsletterPopup")) 3016 { 3017 <div class="newsletter-popup--wrap closed"> 3018 <div class="newsletter-popup"> 3019 <a class="close-popup" href="javascript:void(0);" title="Close"><i class="fa fa-times" aria-hidden="true" style="top: -2px; position: relative;"></i></a> 3020 <h2>@Translate("Signup newsletter", "Signup newsletter")</h2> 3021 3022 3023 <div class="row"> 3024 3025 <div class="col-md-12"> 3026 <!--@Global:Paragraph.Content(@newsletterid)--> 3027 </div> 3028 </div> 3029 3030 3031 </div> 3032 <div class="comfirm-msg" style="display:none;"> 3033 Thank you!<br> 3034 3035 </div> 3036 </div> 3037 <div class="newsletter-popup--teaser opened" style="bottom: 0px; display: block;"> 3038 <a href="javascript:void(0);" title=""> 3039 @Translate("SIGNUP NEWSLETTER", "SIGNUP NEWSLETTER") 3040 </a> 3041 </div> 3042 } 3043 <!--[if IE]> 3044 <style> 3045 3046 .widget.affix{ 3047 3048 width:21% !important; 3049 3050 } 3051 3052 3053 </style> 3054 <![endif]--> 3055 <!-- Essentials --> 3056 <script src="/Files/Templates/Designs/Catago/js/jquery.mousewheel.min.js"></script> 3057 <script src="/Files/Templates/Designs/Catago/js/jquery.easing.min.js"></script> 3058 <script src="/Files/Templates/Designs/Catago/js/jquery.fancybox.min.js"></script> 3059 @*<script src="/Files/Templates/Designs/Eldorado/js/modernizr.min.js"></script>*@ 3060 <script src="/Files/Templates/Designs/Catago/js/bootstrap.min.js"></script> 3061 <script src="/Files/Templates/Designs/Catago/js/typeahead.js"></script> 3062 <script src="/Files/Templates/Designs/Catago/js/blazy.js"></script> 3063 <script src="/Files/Templates/Designs/Catago/js/Request.js"></script> 3064 <script src="/Files/Templates/Designs/Catago/js/handlebars.min.js"></script> 3065 <script src="/Files/Templates/Designs/Catago/js/HandlebarsBolt.js"></script> 3066 <script src="/Files/Templates/Designs/Catago/js/jquerybxslidermin.js"></script> 3067 <script src="/Files/Templates/Designs/Catago/js/jquery.form.js"></script> 3068 <script src="/Files/Templates/Designs/Catago/js/jquery.cookie.min.js"></script> 3069 <script src="/Files/Templates/Designs/Catago/js/GeneralMethods.js"></script> 3070 <script src="/Files/Templates/Designs/Catago/js/cart.js"></script> 3071 3072 <!-- Assets --> 3073 <script src="/Files/Templates/Designs/Catago/js/bootstrap-hover-dropdown.min.js"></script> 3074 3075 <script src="/Files/Templates/Designs/Catago/js/spin.min.js"></script> 3076 3077 <!-- Sripts for individual pages, depending on what plug-ins are used --> 3078 <script type="text/javascript" src="/Files/Templates/Designs/Catago/js/jasny-bootstrap.min.js"></script> 3079 3080 <script src="/Files/Templates/Designs/Catago/js/ProductVariantsAjax.js"></script> 3081 <script src="/Files/Templates/Designs/Catago/js/custom.js"></script> 3082 3083 <script> 3084 $(document).ready(function () { 3085 if (window.location.href.indexOf("?CreatedProfile=True") > -1) { 3086 $(".newsletter-popup--wrap").addClass("open").removeClass("closed"); 3087 } 3088 }); 3089 </script> 3090 <!-- Replacing the Home text --> 3091 <script> 3092 $('#sendform').on('hidden.bs.modal', function () { 3093 $(this).find('form')[0].reset(); 3094 $("#WishListForm .fa-circle-o-notch").remove(); 3095 }); 3096 3097 if (document.getElementById("homemenubtn")) { 3098 document.getElementById("homemenubtn").innerHTML = "<i class='fa fa-home fa-2'></i><span></span>"; 3099 } 3100 </script> 3101 <script> 3102 $("#WishListForm").on("submit", function (e) { 3103 e.preventDefault(); 3104 $("#WishListForm .btn-dw-primary").hide(); 3105 $("#WishListForm .btn-dw-primary").parent().append('<i class=\"fa fa-circle-o-notch fa-spin pull-right\"></i>'); 3106 3107 3108 $.ajax({ 3109 url: '/Default.aspx?ID=11624&PID=17337', 3110 type: "POST", 3111 data: $(this).serialize(), 3112 success: function (data) { 3113 $(".send-form").addClass("hidden"); 3114 $(".confirm-message").removeClass("hidden"); 3115 $(".confirm-message").html(data); 3116 $("#WishListForm .btn-dw-primary").show(); 3117 $("#WishListForm .fa-circle-o-notch").remove(); 3118 }, 3119 3120 }) 3121 }); 3122 </script> 3123 3124 <style> 3125 3126 .second-level .dropdown-menu { 3127 visibility: hidden; 3128 transition: 0.2s 0.2s; 3129 display: unset; 3130 } 3131 3132 .dropdown:hover .dropdown-menu { 3133 visibility: visible; 3134 transition-delay: 0.4s; 3135 } 3136 </style> 3137 3138 <script type="text/html-template" id="OrderlineAjaxTemplate"> 3139 3140 <div class="image Obj.hiddenproduct " data-prodid="Obj.id" data-varid="Obj.variantid"> 3141 <a href="Obj.link"> 3142 <img src="/Admin/Public/GetImage.ashx?width=30&height=30&crop=5&image=Obj.image&Compression=99&altFmImage_path=/Files/Images/Ecom/missing_image.jpg" class="img-center" alt=""> 3143 </a> 3144 <a href="Obj.link"> 3145 Obj.name 3146 </a> 3147 </div> 3148 3149 </script> 3150 3151 <script type="text/html-template" id="NotProductAjaxTemplate"> 3152 <div class="image Obj.hiddenproduct" data-prodid="Obj.id" data-varid="Obj.variantid"> 3153 <a href="Obj.link"> 3154 <img src="/Admin/Public/GetImage.ashx?width=30&height=30&crop=5&image=Obj.image&Compression=99" class="img-center" alt=""> 3155 </a> 3156 <a href="Obj.link"> 3157 Obj.name 3158 </a> 3159 3160 </div> 3161 </script> 3162 3163 3164 <!-- Initialize Fancybox --> 3165 <script type="text/javascript"> 3166 3167 $(document).ready(function () { 3168 MiniCartInit(@JSONFeedForCart, @productsPageId); 3169 if ($('.fancybox').length) { 3170 $(".fancybox").fancybox(); 3171 } 3172 $('.nav-stacked .offcanvas-menubtn').has('ul').addClass('innerMenuMobiletest'); 3173 $("<div class='mobileMenuFix' onclick='toggleCheck(this)'><i class='fa fa-plus'></i></div>").insertBefore(".is-innerMenu"); 3174 $(".nav-stacked .0 i").remove(); 3175 3176 if( $(window).width() > 991) 3177 { 3178 3179 $('.boxes .product').each(function (i) { 3180 var group = $(this); 3181 var groupchild = group.find(".thumbs"); 3182 var groupchildID = groupchild.find("a").attr("data-id"); 3183 var groupchildstock = groupchild.find(".stock-wrapper"); 3184 var groupnumber = groupchild.find("a").attr("data-varnumber"); 3185 var groupname = groupchild.find("a").attr("data-name"); 3186 var groupchildimage = group.find(".large-image"); 3187 var groupImageLarge = groupchildimage.find(".largeImage"); 3188 var groupvariantid = groupchild.find(".variantid").attr("data-id"); 3189 var varainttext = ""; 3190 var groupSizesID = groupchild.find(".variantid").attr("data-id"); 3191 var sizes = group.find(".listproductinfo").find(".sizes"); 3192 var sizesbox = group.find(".large-image").find(".sizes"); 3193 var defaultsizesbox = group.find(".large-image").find(".default-sizes"); 3194 var defaultsizes = group.find(".listproductinfo").find(".default-sizes"); 3195 var defaultnumber = group.find(".listproductinfo").find("p.name"); 3196 var defaultstock = group.find(".listproductinfo").find(".stock-change"); 3197 var defaultname = group.find(".listproductinfo").find(".longproductdescription").find("p.text-center"); 3198 var defaultnamelist = group.find(".extracolumn ").find(".product-title").find("a.link-name"); 3199 var defaultnumberlist = group.find(".shortproductdescription").find("p.name"); 3200 var defaultlink = group.find(".listproductinfo").find(".longproductdescription").find("a"); 3201 var defaultlinkimg = group.find(".listproductright").find(".gallery-container").find("a"); 3202 var favlist = group.find(".product-favorites").find(".product-link"); 3203 groupchild.delegate('img', 'mouseover', function () { 3204 groupImageLarge.attr('src', $(this).attr('src').replace('&height=150&width=150&crop=5', '&height=300&width=300&crop=5&&altFmImage_path=/Files/Images/Ecom/missing_image.gif')); 3205 groupchildID = $(this).closest("a").attr('data-id'); 3206 groupchildVarID = $(this).closest("a").attr('data-varnumber'); 3207 $(this).closest("a").addClass("current"); 3208 $(this).closest('.thumbs').children('.variantid').removeClass('selected'); 3209 $(this).closest('.thumbs').children('.variantid[data-id= '+groupchildID+']').toggleClass('selected'); 3210 groupvariantid = $(this).closest('.thumbs').children(".variantid.selected"); 3211 varainttext = groupvariantid.html(); 3212 groupchildnumber = $(this).closest("a").attr('data-varnumber'); 3213 groupvarnumber = $(this).closest("a").attr('data-varid'); 3214 groupchildname = $(this).closest("a").attr('data-name'); 3215 groupchildlink = $(this).closest("a").attr('data-link'); 3216 3217 defaultnumber.text(groupchildnumber); 3218 defaultname.text(groupchildname); 3219 3220 $(this).closest('.overview').find('.product-container').children(".product-favorites").find('.product-link').addClass("hidden"); 3221 $(this).closest('.overview').find('.product-container').children(".product-favorites").find('.product-link[data-varnumber='+groupchildVarID+']').removeClass('hidden'); 3222 $(this).closest('.overview').find('.product-container').children(".product-favorites").find('.product-link[data-id='+groupchildID+']').removeClass('hidden'); 3223 3224 3225 defaultnumberlist.text(groupchildnumber); 3226 defaultnamelist.text(groupchildname); 3227 defaultlink.attr("href", groupchildlink); 3228 defaultlinkimg.attr("href", groupchildlink); 3229 sizes.removeClass("hidden"); 3230 sizesbox.removeClass("hidden") 3231 sizes.html(varainttext); 3232 sizesbox.html(varainttext); 3233 defaultsizes.addClass("hidden"); 3234 defaultsizesbox.addClass("hidden"); 3235 if(sizes.children(".wrapper-ellisis").height()>25){ 3236 sizes.children(".wrapper-ellisis").css({ 3237 'overflow': 'hidden', 3238 'width': '170px', 3239 'height': '25px' 3240 }) 3241 sizes.children(".read-more").removeClass('hidden').css({ 3242 'display:': 'inline-block' 3243 }) 3244 $('[data-toggle="tooltip"]').tooltip(); 3245 } 3246 3247 }); 3248 3249 group.mouseleave(function(event) { 3250 var src = $(this).find(".large-image").find(".largeImage"); 3251 var number = $(this).find(".listproductinfo").children(".extracolumn").find("p.name"); 3252 var name = $(this).find(".listproductinfo").children(".extracolumn").children(".longproductdescription").find("p.text-center"); 3253 var link = $(this).find(".listproductinfo").children(".extracolumn").children(".longproductdescription").find("a.link-name"); 3254 var linkimg = $(this).find(".listproductright").children(".gallery-container").find("a.link-name"); 3255 var numberlist = $(this).find(".extracolumn").children(".shortproductdescription").find("p.name"); 3256 var namelist = $(this).find(".extracolumn").children(".product-title").find("a.link-name"); 3257 var fav = $(this).find(".product-container").find(".product-favorites").find(".fav"); 3258 var favdef = $(this).find(".product-container").find(".product-favorites").find(".fav.def"); 3259 src.attr('src', src.attr('data-src').replace('&height=150&width=150&crop=5', '&height=300&width=300&crop=5&&altFmImage_path=/Files/Images/Ecom/missing_image.gif'));; 3260 number.text(number.attr('data-defnumber')); 3261 name.text(name.attr('data-defname')); 3262 fav.addClass("hidden"); 3263 favdef.removeClass("hidden"); 3264 link.attr('href', link.attr('data-deflink')); 3265 linkimg.attr('href', link.attr('data-deflink')); 3266 numberlist.text(numberlist.attr('data-defnumber')); 3267 namelist.text(namelist.attr('data-defname')); 3268 namelist.attr('href', namelist.attr('data-deflink')); 3269 defaultsizes.removeClass("hidden"); 3270 sizes.addClass("hidden"); 3271 sizesbox.addClass("hidden"); 3272 $('[data-toggle="tooltip"]').tooltip(); 3273 defaultsizesbox.removeClass("hidden"); 3274 }); 3275 group.click(function() { 3276 $(this).off('mouseover').off('mouseleave') 3277 }); 3278 3279 }); 3280 } 3281 3282 3283 $("#loginform").on("submit", function (l) { 3284 l.preventDefault(); 3285 var username = $(this).find("input[name=username]").val(); 3286 var password = $(this).find("input[name=password]").val(); 3287 $.get("/Default.aspx?ID=@checkuserpageid", { username: username, password: password }) 3288 .done(function (data) { 3289 if ($(data).find(".userid").html() === "0") { 3290 $(".err").html("<label class=\"error no\">@Translate("Wrong username or password", "Wrong username or password")</label>"); 3291 } 3292 if ($(data).find(".userid").html() != "0" && $(data).find(".check-user").html() === "0") { 3293 window.location.reload(); 3294 } 3295 if ($(data).find(".check-user").html() != "0" && $(data).find(".userid").html() != "0") { 3296 window.location.href = "/Default.aspx?ID=@ImpersonationPageId"; 3297 } 3298 if ($(data).find(".userid").html() != "0" && $(data).find(".userGroup").html() === "0" && $(data).find(".check-user").html() === "0") { 3299 window.location.reload(); 3300 } 3301 if ($(data).find(".userGroup").html() != "0" && $(data).find(".userid").html() != "0" && $(data).find(".check-user").html() === "0") { 3302 var homePageId = ""; 3303 if ($(data).find(".userGroup").html() == "pets") { 3304 homePageId = @HomePetId; 3305 } 3306 if ($(data).find(".userGroup").html() == "riding") { 3307 homePageId = @HomeRidingId; 3308 } 3309 if ($(data).find(".userGroup").html() == "petRiding") { 3310 homePageId = @HomePetRidingId; 3311 } 3312 window.location.href = "/Default.aspx?ID="+homePageId; 3313 } 3314 3315 }); 3316 3317 return false; 3318 }); 3319 }); 3320 </script> 3321 3322 <script> 3323 function underlineActiveArea(){ 3324 var areaId = @GetString("DwAreaID")+"area"; 3325 document.getElementById(areaId).className = "activeArea"; 3326 } 3327 underlineActiveArea(); 3328 </script> 3329 <script> 3330 $(".flickerTrigger").hover(function () { 3331 $(".flickerFix").toggleClass("active"); 3332 }); 3333 var searchProducts = new Bloodhound({ 3334 datumTokenizer: Bloodhound.tokenizers.obj.whitespace('value'), 3335 queryTokenizer: Bloodhound.tokenizers.whitespace, 3336 remote: { 3337 url: '/Default.aspx?ID=@productsAjaxPageId&Search=%QUERY', 3338 wildcard: '%QUERY' 3339 } 3340 }); 3341 if ($('#topnavigationmegamenu').children().length == 0){ 3342 $('#topnavigationmegamenu').removeClass("second-level") 3343 } 3344 3345 $('.typeahead-products').typeahead(null, { 3346 name: 'name', 3347 display: 'name', 3348 source: searchProducts, 3349 templates: { 3350 empty: [ 3351 '<div class="empty-message">', 3352 'No results found', 3353 '</div>' 3354 ].join('\n'), 3355 suggestion: Handlebars.compile('<div><a href="{{link}}" title="{{name}}"><img class="tt-img" src="{{image}}" /><strong class="name">{{name}}</strong><div class="tt-price">{{price}}</div><div class="clearfix"></div></a></div>') 3356 } 3357 }); 3358 3359 $('.bxslider').bxSlider({ 3360 mode: 'fade', 3361 captions: true 3362 }); 3363 </script> 3364 <script> 3365 function toggleCheck(elem) { 3366 jQuery(elem).parent().children("ul").toggle(); 3367 jQuery(elem).find(".fa").toggleClass('fa-plus fa-minus'); 3368 } 3369 3370 function toggleCheckTopNav() { 3371 $("#toggleTopNav").children("ul").toggle(); 3372 } 3373 </script> 3374 @RenderSnippet("JavaScriptBottom") 3375 </body> 3376 3377 </html>