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 Newtonsoft.Json.Linq; | |
using System; | |
using System.Collections.Generic; | |
using System.Configuration; | |
using System.Data.SqlClient; | |
using System.Linq; | |
using System.Net; | |
using System.Web.Http; | |
// Note: for this to work, you need to insert this line in the Application_Start event of your global.asax |
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.Configuration; | |
using System.Diagnostics; | |
using System.Web; | |
using Wyam.Core.Execution; | |
using Wyam.Core.Modules.Contents; | |
using Wyam.Core.Modules.Control; | |
using Wyam.Core.Modules.IO; | |
using Wyam.Core.Modules.Metadata; | |
using Wyam.Markdown; |
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
<form method="post" action="/social/comments/add" id="commentForm"> | |
<input type="hidden" name="pageId" value="@Model.CurrentPage.ContentGuid"/> | |
<input type="text" name="author" placeholder="Your name..."/> | |
<textarea name="body" id="commentBody" placeholder="Your comment..."></textarea> | |
<br/> | |
<input type="submit" id="commentSubmitButton" disabled="disabled" style="opacity: 0.5;" value="Submit" /> | |
</form> | |
<div id="commentList"> | |
Loading comments... |
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
<html> | |
<head> | |
<link href="https://contentful.github.io/ui-extensions-sdk/cf-extension.css" rel="stylesheet"> | |
<script src="https://contentful.github.io/ui-extensions-sdk/cf-extension-api.js"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/mustache.js/2.2.1/mustache.min.js"></script> | |
<style> | |
body { | |
margin: 0; | |
color: #8091a5 !important; | |
overflow: hidden; |
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 EPiServer.Core; | |
using EPiServer.Framework; | |
using EPiServer.Framework.Initialization; | |
using EPiServer.ServiceLocation; | |
using EPiServer.Web; | |
using System.Linq; | |
using System.Web; | |
namespace BlendInteractive.Business | |
{ |
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 EPiServer.Enterprise; | |
using EPiServer.Enterprise.Mirroring; | |
using EPiServer.Framework; | |
using EPiServer.Framework.Initialization; | |
using EPiServer.MirroringService; | |
using EPiServer.MirroringService.Common; | |
using EPiServer.MirroringService.MirroringMonitoring; | |
using EPiServer.MirroringService.MirroringTransferProtocol.Common; | |
using System; | |
using System.Linq; |
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
define( | |
["dojo/_base/declare", "dojo/ready", "dijit/_Widget", "dijit/_TemplatedMixin", "epi/epi"], | |
function (declare, ready, _Widget, _TemplatedMixin, epi) { | |
return declare( | |
[_Widget, _TemplatedMixin], | |
{ | |
templateString: '<textarea data-dojo-attach-event="onchange:_onChange"></textarea>', | |
constructor: function () { | |
ready(this, function () { |
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 you think it's brilliant, then this is completely intentional. | |
// If you think it's dumb, then this is intended ironically because I'm just _that_ smart. | |
StringMatcher.IsMatch("Deane Barker", "deane ", StringMatchMethod.Starts, StringMatchOptions.IgnoreCase | StringMatchOptions.Trim); // True | |
StringMatcher.IsMatch("Deane Barker", "Barker", StringMatchMethod.Ends); // True | |
StringMatcher.IsMatch("Deane Barker", "ARK", StringMatchMethod.Contains, StringMatchOptions.IgnoreCase); // True | |
// etc. | |
// In reality, this is intended for use with a particular CMS, so that the editing interface can be dynamically generated | |
// based on the code. A dropdown will generate for the values in StringMatchMethod, and checkboxes will generate for the |
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 XmlNode : Drop | |
{ | |
private const string attributeMethodName = "attr"; | |
private const string xpathQueryMethodName = "xpath"; | |
private const string listQueryMethodName = "list"; | |
private const char shorthandDelimiter = '-'; | |
private XmlElement doc; | |
public XmlNode(XmlDocument xml) |
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
<!-- | |
This is a textarea that: | |
(1) Is styled(-ish) like a code editor | |
(2) Catches tabs and converts them to four (4) spaces | |
(3) Duplicates leading spaces from the last line | |
(4) Auto-expands to input | |
Pure inline HTML and JavaScript. No external dependencies. Has issues pre-IE-8, but should be otherwise okay. |
OlderNewer