This file contains hidden or 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 ContactController : Umbraco.Web.Mvc.SurfaceController | |
{ | |
[ChildActionOnly] | |
public ActionResult ContactForm() | |
{ | |
var model = new ContactModel(); | |
//Initialize model however you want | |
model.FullName = "Enter your name"; |
This file contains hidden or 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
@inherits Umbraco.Web.Macros.PartialViewMacroPage | |
@{ | |
var home = Model.Content.AncestorsOrSelf().First(); | |
} | |
@helper Traverse(IPublishedContent node, int pad) | |
{ | |
<li> | |
<a href="@node.Url">@(!String.IsNullOrWhiteSpace(node.GetPropertyValue<string>("pageName")) ? node.GetPropertyValue<string>("pageName") : !String.IsNullOrWhiteSpace(node.GetPropertyValue<string>("pageTitle")) ? node.GetPropertyValue<string>("pageTitle") : node.Name)</a> |
This file contains hidden or 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 Examine.LuceneEngine.SearchCriteria | |
@inherits Umbraco.Web.Macros.PartialViewMacroPage | |
@{ | |
string searchTerm = Request.QueryString["keywords"]; | |
if (String.IsNullOrWhiteSpace(searchTerm)) | |
{ | |
searchTerm = ""; | |
} |