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 express = require('express'); | |
var fs = require('fs'); | |
var app = express(); | |
app.get('/logJson', function (req, res) { | |
const logsFolder = '/folder/path/'; | |
fs.readdir(logsFolder, (err, files) => { | |
if (err) { |
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 Sitecore.Configuration; | |
using Sitecore.Data.Items; | |
using Sitecore.Data; | |
using Sitecore.Data.Fields; | |
namespace sitecore.local.CustomCode | |
{ | |
public class ItemMoving | |
{ | |
private readonly Database _sourceDatabase = Factory.GetDatabase("master"); |
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
<?xml version="1.0" encoding="utf-8"?> | |
<configuration> | |
<sitecore> | |
<scheduling> | |
<!--Custom Code that will do item moving--> | |
<agent type="sitecore.local.CustomCode.ItemMoving" method="Execute" interval="00:00:59"/> | |
</scheduling> | |
</sitecore> | |
</configuration> |
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 Sitecore.Mvc | |
@using Sitecore.Mvc.Extensions | |
@using sitecore.local.Controllers | |
@{ | |
Layout = null; | |
} | |
<!DOCTYPE html> | |
<html> | |
<head> |
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.Web; | |
using System.Web.Mvc; | |
using Sitecore.Mvc.Extensions; | |
namespace sitecore.local.Controllers | |
{ | |
public static class Angular | |
{ | |
public static IHtmlString RawJsEncodedString<T>(this HtmlHelper<T> htmlHelper, HtmlString str) | |
{ |
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
angular.module('sc.sample', [ | |
'ngSanitize' | |
]).directive('sampleComponent', function () { | |
return { | |
scope: { | |
data: '=sampleComponent' | |
}, | |
templateUrl: `[template path]/index.html` | |
}; | |
}).controller('SampleDemoController', ['$scope', function ($scope) { |
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
<section class="row page-header sampleComponent spaced-row" ng-show="data"> | |
<div class="col-xs-12"> | |
<h1 class="header" ng-bind-html="data.Title | asTrusted"></h1> | |
</div> | |
<article class="col-xs-7 col-md-8"> | |
<p ng-bind-html="data.Text | asTrusted"></p> | |
</article> | |
<figure class="col-xs-5 col-md-4"> | |
<span ng-bind-html="data.Image | asTrusted"></span> | |
</figure> |
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
<?xml version="1.0" encoding="utf-8"?> | |
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/" xmlns:role="http://www.sitecore.net/xmlconfig/role/"> | |
<sitecore role:require="ContentDelivery or Reporting or Processing"> | |
<settings> | |
<setting name="ContentTesting.AutomaticContentTesting.Enabled" value="false" /> | |
<setting name="ContentTesting.AlwaysShowTestCandidateNotification" value="false" /> | |
</settings> | |
<pipelines> | |
<renderingRuleEvaluated> | |
<processor type="Sitecore.ContentTesting.Pipelines.RenderingRuleEvaluated.TestingRule, Sitecore.ContentTesting"> |
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
yourApplicationName/data/routes/en.yml |
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
import React from 'react'; | |
import { Text, Image } from '@sitecore-jss/sitecore-jss-react'; | |
const Profile = (props) => ( | |
<div className="col-md-8"> | |
<Image | |
field={props.fields.avatar} | |
className="avatar" | |
/> | |
<h1><Text field={props.fields.name} /></h1> |
OlderNewer