Skip to content

Instantly share code, notes, and snippets.

View kevinobee's full-sized avatar

Kevin Obee kevinobee

  • Canterbury, UK
  • 02:09 (UTC +01:00)
View GitHub Profile
using System;
namespace @abstract // learnt something here, how to handle a reserved word as a namespace, obviously a similar thing
{
class Program
{
static void Main(string[] args)
{
var session = new Session();
var builder = new DetailsViewModelBuilder();
@kevinobee
kevinobee / GetDataController.cs
Created November 28, 2012 08:47
Multiple GET methods with WebApi
using System.Net.Http;
using System.Web.Http;
namespace MvcApplication1.Controllers
{
public class GetDataController : ApiController
{
public string Get()
{
return Request.RequestUri.Host;
@kevinobee
kevinobee / sc_cmdlet_list.ps1
Created November 28, 2012 14:29
Sitecore powershell console list of CmdLets
Get-Command | where { ($_.ImplementingType.Assembly -ne $null) -and ($_.ImplementingType.Assembly.GetName().Name.StartsWith("Cognifide.PowerShell")) }
using System;
using System.Web.Mvc;
using System.Web.Routing;
namespace Mvc.Website
{
public class MvcApplication : Sitecore.Web.Application
{
public static void RegisterRoutes(RouteCollection routes)
{
<!doctype html>
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />
<script>
function testcase() {
var img = new Array();
/// <reference path="../jquery-1.7.2-vsdoc.js" />
/// <reference path="../jquery-ui-1.8.20.js" />
/// <reference path="../knockout-2.1.0.debug.js" />
/// <reference path="../knockout.mapping-latest.debug.js" />
/// <reference path="../bootstrap-modal.js" />
/// <reference path="../moment.js" />
var mi = mi || {};
$(document).ready(function () {
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
<sitecore>
<encodeNameReplacements>
<replace patch:before="*[1]" mode="on" find=" " replaceWith="-" />
</encodeNameReplacements>
</sitecore>
</configuration>
<?xml version="1.0"?>
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
<sitecore>
<settings>
<setting name="Login.RememberLastLoggedInUserName" value="false"/>
</settings>
</sitecore>
</configuration>
@kevinobee
kevinobee / gist:8296203
Created January 7, 2014 08:22
Metadata
{
"actions": {
"GET": [
{
"FetchEntities": {
"returnType": "SitecoreCms.Models.SimpleData[]",
"properties": {}
}
},
{
7zip 16.02
7zip.install 16.02
agentransack 7.0.828.1
autohotkey.portable 1.1.24.00
chocolatey 0.9.10.3
dependencywalker 2.2.6000.7
docker 1.12.0
DotNet4.5.2 4.5.2.20140902
Evernote 5.9.9.9915
fiddler4 4.6.2.29442