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
c:\path\to\doc\root>make html > log.txt 2>&1 |
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 Contacts : IHttpHandler, IRequiresSessionState | |
{ | |
public void ProcessRequest(HttpContext context) | |
{ | |
try | |
{ | |
bool flag = false; | |
ID id; | |
// Get contact data from query string |
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
[HttpPost] | |
public ActionResult ImportContacts() | |
{ | |
// For the purposes of this example, the dictionary key represents the contact identifier | |
// and the value represents their first name | |
var contacts = new Dictionary<string, string>(); | |
contacts.Add("martina_welander", "Martina"); | |
contacts.Add("bob_mcbob", "Bob"); |
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
[HttpPost] | |
public ActionResult SubmitForm(string jobRole) | |
{ | |
if (Tracker.Current != null && | |
Tracker.IsActive == true && | |
Tracker.Current.Contact != null) | |
{ | |
var personalFacet = Tracker.Current.Contact.GetFacet<IContactPersonalInfo>("Personal"); | |
personalFacet.JobTitle = jobRole; |
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
[HttpPost] | |
public ActionResult LoginUser(string username) | |
{ | |
if (Tracker.Current != null && | |
Tracker.IsActive == true) | |
{ | |
Tracker.Current.Session.Identify(username); | |
} | |
// The user is also logged in using normal ASP.NET membership; this is a completely separate process from identifying |
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
ContactManager contactManager = Sitecore.Configuration.Factory.CreateObject("tracking/contactManager", true) as ContactManager; | |
contactManager.FlushContactToXdb(contact); | |
contactManager.SaveAndReleaseContactToXdb(contact); |
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.Analytics.Model.Framework; | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
namespace xDB.Workshop.Facets | |
{ | |
/// <summary> | |
/// |
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
namespace TC.ServicesPortal.ModelBinders | |
{ | |
public class InterfaceModelBinder : DefaultModelBinder | |
{ | |
protected override object CreateModel(ControllerContext controllerContext, ModelBindingContext bindingContext, Type modelType) | |
{ | |
var type = bindingContext.ModelType; | |
if (type.IsInterface) | |
{ |