Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
<div class="flex space-x-2 mb-4 rounded border text-center text-sm font-bold"> | |
<div class="flex-1 p-2"><span class="text-green-700 mr-1 xs:inline-block sm:hidden">✓</span><span class="text-red-700 mr-1 hidden sm:inline-block">✗</span><br>XS</div> | |
<div class="flex-1 p-2"><span class="text-green-700 mr-1 hidden sm:inline-block md:hidden">✓</span><span class="text-red-700 mr-1 inline-block sm:hidden md:inline-block">✗</span><br>SM</div> | |
<div class="flex-1 p-2"><span class="text-green-700 mr-1 hidden md:inline-block lg:hidden">✓</span><span class="text-red-700 mr-1 inline-block md:hidden lg:inline-block">✗</span><br>MD</div> | |
<div class="flex-1 p-2"><span class="text-green-700 mr-1 hidden lg:inline-block xl:hidden">✓</span><span class="text-red-700 mr-1 inline-block lg:hidden xl:inline-block">✗</span><br>LG</div> | |
<div class="flex-1 p-2"><span class="text-green-700 mr-1 hidden xl:inline-block 2xl:hidden">✓</span><span class="text-red-700 mr-1 |
This file contains 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
document.getElementById('canvas').toBlob(function(blob){ | |
var image = document.createElement('img'); | |
var url = URL.createObjectURL(blob); | |
image.onload = function() { | |
URL.revokeObjectURL(url); | |
} | |
console.log(url); | |
image.src = url; | |
document.body.appendChild(image); | |
}); |
This file contains 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 C2 contains a DateTimeOffset eg 2015-08-13 09:31:12.0000000 +01:00 | |
* parse the date and time out and add them together | |
* then subtract the hours offset (which - in Excel time storage is hours/24) | |
* note that this ignores the minute-part of an offset (eg Venezuela) | |
*/ | |
=DATE(LEFT($C2,4), MID($C2,6,2),MID($C2,9,2)) + TIME(MID($C2,12,2),MID($C2,15,2),MID($C2,18,2)) + (MID($C2,29,3)/24) |
This file contains 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
-- Takes a timestamp (in seconds) and a timezone offset (eg +0730) and returns a timestamp | |
CREATE TEMPORARY FUNCTION applyTZOffsetToUnixTimestamp(ts INT64, tzOffset STRING) | |
RETURNS INT64 AS ( | |
CASE | |
WHEN SUBSTR(tzOffset, 1, 1) = '+' THEN ts + (CAST(SUBSTR(tzOffset, 2, 2) AS INT64) * 60 * 60) + (CAST(SUBSTR(tzOffset, 4, 2) AS INT64) * 60) | |
WHEN SUBSTR(tzOffset, 1, 1) = '-' THEN ts - (CAST(SUBSTR(tzOffset, 2, 2) AS INT64) * 60 * 60) - (CAST(SUBSTR(tzOffset, 4, 2) AS INT64) * 60) | |
ELSE NULL | |
END | |
); |
This file contains 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
var market = MarketInfo.Markets.SingleOrDefault(m => m.Code == Visitor.CountryCode); | |
if (market == null) | |
market = Visitor.Market; |
This file contains 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
@{ | |
LinkField URL = item.Fields["URL"]; | |
if (URL != null) | |
{ | |
<a href="@URL.Url" target="@URL.Target" title="@URL.Title">@URL.Title ></a> | |
} | |
} |
This file contains 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
<ul> | |
<asp:Repeater ID="rpFooterDestinations" runat="server"> | |
<ItemTemplate> | |
<li> | |
<a href="<%# Sitecore.Links.LinkManager.GetItemUrl( | |
(Sitecore.Data.Items.Item) Container.DataItem | |
) %>"><%# Eval("DisplayName") %></a> | |
</li> | |
</ItemTemplate> | |
</asp:Repeater> |
This file contains 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
ids.ForEach(id => { | |
itineraries.Add(Sitecore.Context.Database.GetItem(id)); | |
}); |
This file contains 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
List<Item> items = (Sitecore.Context.Item.Axes.SelectItems(query) ?? new Item[] { }).ToList(); |
NewerOlder