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.Linq; | |
using Umbraco.Core; | |
using Umbraco.Core.Logging; | |
using Umbraco.Web; | |
namespace Sniper.Umbraco | |
{ | |
public static class MultiNodeTreePickerIdToUdiMigrator | |
{ |
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.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using Simple.Data; | |
using Examine.LuceneEngine; | |
using Examine; | |
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
@inherits Umbraco.Web.Macros.PartialViewMacroPage | |
@using Examine | |
@using Examine.SearchCriteria | |
@using Examine.LuceneEngine.SearchCriteria | |
@{ | |
//Get search query | |
var q = Request.QueryString["q"]; | |
//Check if searchQuery is null from the posted form data... | |
if (q == null) |
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
<?php | |
$rss = new DOMDocument(); | |
$rss->load('http://feeds.bbci.co.uk/news/rss.xml'); | |
$feed = array(); | |
foreach ($rss->getElementsByTagName('item') as $node) { | |
$item = array ( | |
'title' => $node->getElementsByTagName('title')->item(0)->nodeValue, | |
'desc' => $node->getElementsByTagName('description')->item(0)->nodeValue, | |
'link' => $node->getElementsByTagName('link')->item(0)->nodeValue, | |
'date' => $node->getElementsByTagName('pubDate')->item(0)->nodeValue, |
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
@inherits Umbraco.Web.Macros.PartialViewMacroPage | |
@{umbraco.library.ChangeContentType("text/xml"); | |
var siteURL = "http://" + Request.Url.Host; | |
var HomePage = CurrentPage.AncestorOrSelf(1); | |
var RSSFeedPubDate = HomePage.Descendants("PressRelease").OrderBy("publishedDate desc").First(); | |
}<?xml version="1.0" encoding="UTF-8"?> | |
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rssdatehelper="urn:rssdatehelper"> |
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 umbraco.cms.businesslogic.Tags | |
@inherits Umbraco.Web.Mvc.UmbracoTemplatePage | |
@{ | |
var blogTags = Tag.GetTags("default").OrderByDescending(t => t.NodeCount); | |
} | |
<h4>Tags</h4> | |
<ul> | |
@foreach (var t in blogTags) | |
{ | |
<li><a href='/[email protected]' title='@t.TagCaption'>@t.TagCaption (@t.NodeCount)</a></li> |
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
<ol class="breadcrumb"> | |
<li>You are here:</li> | |
@foreach (var ancestor in CurrentPage.Ancestors().Where("Visible")) | |
{ | |
<li><a href="@ancestor.Url" title="@ancestor.Name">@ancestor.Name</a> > </li> | |
} | |
<li class="active">@CurrentPage.Name</li> | |
</ol> |