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
bool isManual = false; | |
if (context != null) | |
{ | |
var jobId = context.BackgroundJob?.Id; | |
if (jobId != null) | |
{ | |
var jobDetails = JobStorage.Current.GetMonitoringApi().JobDetails(jobId); | |
if (jobDetails != null) | |
isManual = jobDetails.History.ToList() |
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 Microsoft.Extensions.Logging; | |
using Microsoft.Extensions.Options; | |
using Umbraco.Cms.Core.Configuration.Models; | |
using Umbraco.Cms.Core.Models.PublishedContent; | |
using Umbraco.Cms.Core.Routing; | |
using Umbraco.Cms.Core.Services; | |
using Umbraco.Cms.Core.Web; | |
public class HomePageUrlProvider : DefaultUrlProvider | |
{ |
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
# Set the directory path where you want to search | |
$directory = "E:\\" | |
# Get files matching the specified pattern and older than 90 days | |
$files = Get-ChildItem -Path $directory -Filter "UmbracoTraceLog*" -Recurse | Where-Object { $_.LastWriteTime -lt (Get-Date).AddDays(-90) } | |
$count = $files.Count | |
Write-Host "Number of files found: $count" |
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
select * from cmsDataType where nodeId = ID | |
update cmsDataType set propertyEditorAlias = 'Umbraco.DropDown.Flexible' where nodeId = ID | |
select * from cmsDataTypePreValues where datatypeNodeId = ID | |
insert into cmsDataTypePreValues (alias, sortorder, [value], datatypeNodeId) values ('multiple', 7, '0', ID) |
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
DECLARE @AlterStatements TABLE ( | |
Statement NVARCHAR(MAX) | |
) | |
INSERT INTO @AlterStatements (Statement) | |
SELECT 'ALTER INDEX [' + I.name + '] ON [' + T.name + '] REBUILD' | |
FROM sys.indexes I | |
INNER JOIN sys.tables T ON I.object_id = T.object_id | |
WHERE I.type_desc = 'NONCLUSTERED' | |
AND I.name IS NOT 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
<script id="gtmScript" data-nonce="@Html.CspScriptNonceValue()"> | |
(function (w, d, s, l, i) { | |
w[l] = w[l] || []; w[l].push({ | |
'gtm.start': | |
new Date().getTime(), event: 'gtm.js' | |
}); var f = d.getElementsByTagName(s)[0], | |
j = d.createElement(s), dl = l != 'dataLayer' ? '&l=' + l : ''; j.async = true; j.src = | |
'https://www.googletagmanager.com/gtm.js?id=' + i + dl; var n = d.querySelector('[nonce]'); | |
n && j.setAttribute('nonce', n.nonce || n.getAttribute('nonce')); f.parentNode.insertBefore(j, f); | |
})(window, document, 'script', 'dataLayer', '###-#######');</script> |
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.Cms.Core.Models.PublishedContent; | |
using Umbraco.Cms.Core; | |
using Umbraco.Cms.Core.PropertyEditors.ValueConverters; | |
using Umbraco.Cms.Core.PublishedCache; | |
using Umbraco.Cms.Core.Composing; | |
using Umbraco.Cms.Core.DependencyInjection; | |
using Umbraco.Cms.Core.Services; | |
public class IntFriendlyMediaPickerValueConverter : MediaPickerValueConverter | |
{ |
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
<%@ Page Language="vb" %> | |
<html> | |
<head> | |
<title>Showing HTTP Headers via the Headers Collection in ASP.NET</title> | |
</head> | |
<body> | |
<% | |
Dim AllHttp As String |
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
.\wacs.exe --installation script --script "Scripts\ImportWMSVC.ps1" --scriptparameters "'{CertThumbprint}'" --certificatestore My |
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
public interface IValidateYubiKeyOTPService | |
{ | |
Task<bool> ValidateYubiKey(string otp); | |
} |
NewerOlder