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.StaticAssets.Html.Helpers | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8" /> | |
@StaticAssets.RenderStyle("/dist/styles/styles.all.css") | |
</head> | |
<body> | |
@RenderBody() |
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
ISearchIndex index = ContentSearchManager.GetIndex("sitecore_master_index") | |
using (IProviderSearchContext context = index.CreateSearchContext()) | |
{ | |
var results = context.GetQueryable<SearchResultItem>() | |
.Where(x => x.Content.Contains("Is that you, John Wayne? Is this me?")); | |
} |
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 ContactManager() | |
{ | |
// Code omitted | |
this.sharedSessionStateManager.ContactExpired += new Action<Contact>(this.SaveAndReleaseContactToXdb); | |
// Code omitted | |
} |
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 CustomGetLinkFieldValue : Sitecore.Pipelines.RenderField.GetLinkFieldValue | |
{ | |
protected override Sitecore.Xml.Xsl.LinkRenderer CreateRenderer(Item item) | |
{ | |
return new CustomLinkRenderer(item); | |
} | |
} |
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 CustomLinkRenderer : Sitecore.Xml.Xsl.LinkRenderer | |
{ | |
public LinkRenderer(Item item) : base(item) | |
{ | |
} | |
protected override string GetUrl(XmlField field) | |
{ | |
if (field != null) | |
return new CustomLinkUrl().GetUrl(field, this.Item.Database); |
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 CustomLinkUrl : Sitecore.Xml.Xsl.LinkUrl | |
{ | |
protected override string GetInternalUrl(Database database, string url, string itemID, string anchor, string queryString) | |
{ | |
Assert.ArgumentNotNull(database, "database"); | |
Assert.ArgumentNotNull(url, "url"); | |
Assert.ArgumentNotNull(itemID, "itemID"); | |
Assert.ArgumentNotNull(anchor, "anchor"); | |
Assert.ArgumentNotNull(queryString, "queryString"); |
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
protected virtual string GetInternalUrl(Database database, string url, string itemID, string anchor, string queryString) | |
{ | |
// Asserts omitted... | |
Item obj = database.Items[url] ?? database.Items[itemID]; | |
if (obj == null) | |
return string.Empty; | |
if (obj.Paths.IsMediaItem) |
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
protected virtual string GetInternalUrl(Database database, string url, string itemID, string anchor, string queryString) | |
{ | |
// Asserts omitted... | |
Item obj = database.Items[url] ?? database.Items[itemID]; | |
if (obj == null) | |
return string.Empty; | |
if (obj.Paths.IsMediaItem) |
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
<binding hostName="localhost" | |
useWindowsAuth="false" | |
userName="sitecore\admin" | |
password="b" | |
dataService="Hard Rock Web Service" | |
webRootPath="C:\path-to-your-sitecore-site\Website" | |
description="sitecore-solution.local" | |
isRemoteSitecore="false" | |
automaticallyUpdate="true" | |
isHidden="false" |
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
41520 09:07:50 WARN Crawler : AddRecursive DoItemAdd failed - {C9AC9FAD-28E1-48BD-A86B-ABF40C15D3EA} | |
Exception: SolrNet.Exceptions.SolrConnectionException | |
Message: <?xml version="1.0" encoding="UTF-8"?> | |
<response> | |
<lst name="responseHeader"> | |
<int name="status">400</int><int name="QTime">61</int></lst><lst name="error"> | |
<str name="msg"> | |
ERROR: [doc=sitecore://master/{66804041-d7cc-4371-b013-8e1df7b5ffcd}?lang=en&ver=1&ndx=sitecore_master_index] | |
Error adding field 'version__im'='xyz' msg=For input string: "xyz" | |
</str> |