This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.table([...products].map(p => { | |
var o = {}; | |
o.name = p.querySelector(".product__name").innerText; | |
o.description = [...p.querySelectorAll(".product__description-list > :not(:last-child)")].map(d => d.innerText).join(" "); | |
o.articlenumber = p.querySelector(".product_description-article-number").innerText; | |
o.price = (p.querySelector(".product__price-regular") || p.querySelector(".product__total")).innerText; | |
o.quantity = p.querySelector(".product-controls__quantity select").value; | |
o.total = p.querySelector(".product__total").innerText; | |
return o; | |
})); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INSERT INTO [dbo].[SkybrudRedirects] (RedirectUniqueId, RootNodeId, Url, LinkMode, LinkId, LinkUrl, Created, Updated, IsPermanent, IsRegex, ForwardQueryString) | |
SELECT NEWID(), 0, OldUrl, 'url', 0, NewUrl, 1562836223, 1562836223, 1, IsRegex, 1 FROM [dbo].[Redirects]; | |
SELECT TOP (1000) [RedirectId] | |
,[RedirectUniqueId] | |
,[RootNodeId] | |
,[Url] | |
,[QueryString] | |
,[LinkMode] | |
,[LinkId] | |
,[LinkUrl] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@using Our.Umbraco.DocTypeGridEditor.Helpers | |
@using Our.Umbraco.DocTypeGridEditor.Web.Extensions | |
@inherits UmbracoViewPage<GridControl> | |
@* | |
This view converts the dynamic Doc Type Grid Editor model to the parts needed for firing up the view | |
for DTGE based editors. It then uses DTGEs own methods for rendering the needed partial views. | |
We could do a strongly typed edition of this, but since this is a one-off and we probably never have | |
to edit this particular view, we didn't. | |
*@ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://our.umbraco.com/forum/extending-umbraco-and-using-the-api/86507-can-i-use-rout-attributes-in-umbraco-controllers# | |
[RoutePrefix("api/v1/products")] | |
public class ProductsController : UmbracoApiController | |
{ | |
[Route("")] | |
public List<Product> GetAllProducts() | |
{ | |
return null; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@using Umbraco.Core.Models; | |
@using Umbraco.Web; | |
@using System.Collections.Generic; | |
namespace skttl.UmbracoExtensions | |
{ | |
public static class UmbracoHelperExtensions | |
{ | |
public static IEnumerable<IPublishedContent> TypedContentAtRelativeXPath(this UmbracoHelper helper, IPublishedContent current, string xpath) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
version: 1.0 | |
domains: | |
- www.youtube.com | |
url_patterns: | |
- www.youtube.com/* | |
timestamp: '2018-08-02T20:46:51Z' | |
id: pqTX | |
redirect_url: https://www.youtube.com/watch?v=s0vg_H9hBuU | |
shared_via: StyleURL - (https://styleurl.app) import and export CSS changes from Chrome |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Newtonsoft.Json; | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
namespace Umbraco.Core.Models | |
{ | |
public class NestedContent : List<NestedContentItem> | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@inherits UmbracoViewPage<dynamic> | |
@using Umbraco.Web.Templates | |
@using Newtonsoft.Json.Linq | |
@* this is my custom grid rendering | |
Note the function IsAreaVisible at line 69, which takes the UmbracoHelper (for getting the current member) and the area (for reading the visibility-setting) | |
In the rendering, IsAreaVisible is used at line 50 | |
*@ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin outline-text($width:1px, $color:#fff) { | |
$text-shadow-result: "0 0 0 #{$color}"; | |
@for $y from -$width through $width { | |
@for $x from -$width through $width { | |
$text-shadow-result: #{append($text-shadow-result, ", #{$y} #{$x} 0 #{$color}")}; | |
} | |
} | |
text-shadow:$text-shadow-result; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (localStorage.getItem("metalliganot_following") == null) | |
{ | |
localStorage.setItem("metalliganot_following", "[]"); | |
} | |
function addFollowButtons() | |
{ | |
const games = document.querySelectorAll(".live .game"); |