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
Get-ChildItem -Filter *.csproj -Recurse | | |
Select-Object -Property FullName,@{N="Xml"; E = { | |
Select-Xml -Path $_.FullName -XPath //b:Reference -Namespace @{b='http://schemas.microsoft.com/developer/msbuild/2003'} | | |
Select-Object -ExpandProperty Node | | |
Select-Object -Property Include, HintPath | | |
Where-Object { $_.HintPath -ne $null } | | |
Where-Object { $_.Include -eq "My.Assembly.Name" } | |
} } | | |
Where-Object { $_.Xml -ne $null } | | |
Out-GridView |
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
<siteMap defaultProvider="UmbracoSiteMapProvider" enabled="true"> | |
<providers> | |
<clear /> | |
<add name="UmbracoSiteMapProvider" type="umbraco.presentation.nodeFactory.UmbracoSiteMapProvider" defaultDescriptionAlias="description" securityTrimmingEnabled="true" /> | |
</providers> | |
</siteMap> |
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
Key Name Resulting Keystroke | |
{F1} - {F24} Function keys. For example: {F12} is the F12 key. | |
{!} ! | |
{#} # | |
{+} + | |
{^} ^ | |
{{} { | |
{}} } | |
{Enter} ENTER key on the main keyboard | |
{Escape} or {Esc} ESCAPE |
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
Update-ExecutionPolicy Unrestricted | |
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar | |
Disable-UAC | |
Disable-InternetExplorerESC | |
cinst TelnetClient -source windowsFeatures | |
cinst IIS-WebServerRole -source windowsFeatures | |
cinst UrlRewrite | |
cinst msdeploy3 |
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
public bool TryFindContent(PublishedContentRequest contentRequest) | |
{ | |
if (contentRequest.Is404) | |
{ | |
var site = SiteHelpers.GetSite(); | |
var page404 = site.Get404Page(); | |
if (page404 != null) | |
{ | |
contentRequest.PublishedContent = contentRequest.RoutingContext.UmbracoContext.ContentCache.GetById(page404.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
public class ContextHelpers | |
{ | |
public static UmbracoContext EnsureUmbracoContext() { | |
if (UmbracoContext.Current != null) | |
{ | |
return UmbracoContext.Current; | |
} | |
var httpContext = new HttpContextWrapper(HttpContext.Current ?? new HttpContext(new SimpleWorkerRequest("temp.aspx", "", new StringWriter()))); | |
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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using Umbraco.Core; | |
namespace Meh.App_Code | |
{ | |
public class ChangeMenu : ApplicationEventHandler | |
{ |
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
public class Global : HttpApplication | |
{ | |
protected void Application_Start(object sender, EventArgs e) | |
{ | |
umbracoPage.Load += InjectJavascript; | |
} | |
private void InjectJavascript(object sender, EventArgs eventArgs) | |
{ | |
var page = sender as umbracoPage; |
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 formHasChanged = false; | |
var formEl = $('form'); | |
formEl.on('change', function () { | |
formHasChanged = true; | |
}); | |
var hasUnsavedChanges = function () { | |
for (var editorId in tinyMCE.editors) { | |
var editor = tinyMCE.editors[editorId]; |
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
using System; | |
using System.Collections.Generic; | |
using System.Configuration; | |
using System.IO; | |
using System.Linq; | |
using System.Text.RegularExpressions; | |
using System.Web; | |
using Google.GData.Analytics; | |
using Google.GData.Client; | |
using ServiceStack.Text; |
NewerOlder