Skip to content

Instantly share code, notes, and snippets.

Sebastiaan Janssen nul800sebastiaan

Block or report user

Report or block nul800sebastiaan

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:63b4adac09a07cda521f
propertyEditors: [
alias: "My.CustomEditor",
name: "Custom Editor",
editor: {
view: "~/App_Plugins/CustomEditor/customeditor.html"
View gist:e2ad23898423768be388
DF_cmsMacroProperty_macroPropertyHidden was called DF_macroProperty_macroPropertyHidden at some point (cmsMacroProperty table)
FK_cmsMacroProperty_cmsMacroPropertyType_id was called FK_umbracoMacroProperty_umbracoMacroPropertyType at some point (cmsMacroProperty table)
FK_cmsTagRelationship_umbracoNode_id was called umbracoNode_cmsTagRelationship at some point (cmsTagRelationship table)
So just rename these three from their old name (on the right) to their "expected" name (left)
View gist:79680fd9418d4f6408a9
.NET Framework 4.5 selected
File > New Project > Visual C# > Web > ASP.NET Web Application > Empty
In Package Manager Console, selected as source
Install-Package UmbracoCms
F5 to run and install Umbraco
After that succeeds, back to Package Manager Console
update-package ImageProcessor -Source D:\Dropbox\Windows\Downloads
update-package ImageProcessor.Web -Source D:\Dropbox\Windows\Downloads
- Obviously "Source" is the folder where the downloaded nupkg files are
View gist:8b9936fc767433ed67e1
After installing
Server Error in '/' Application.
Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: ImageProcessor.Common.Exceptions.ImageFormatException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
View gist:0cc0d9f5efe579475e33
<smtp deliveryMethod="SpecifiedPickupDirectory">
pickupDirectoryLocation="D:\Level1MasterclassAugust2014\UmbracoCms.7.2.0-alpha\App_Data\mail" />
View gist:c55db724eaf6c0d73899
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Umbraco.Web.WebApi;
using Umbraco.Web.Mvc;
namespace My.Controllers
View gist:e20ebddda74f4fe254cd
Upgrading note
Google Chrome has notoriously aggressive caching, so if something doesn't seem to work
well in the backoffice, make sure to clear cache and cookies thoroughly (for other
browsers as well).
One way to nudge the cache in Chrome is to open the developer tools (F12) and go to the
settings (the cog icon). There will be a checkbox that says "Disable cache (while
DevTools is open)". Once this checkbox is on you can refresh the page and the cache
should be invalidated. To force it even more, the "reload" button next to your address
View gist:b9755c5e06a97cb3000b
"propertyEditors": [
"alias": "Long.Textarea",
"name": "Long Textarea",
"editor": {
"view": "~/App_Plugins/LongTextarea/longtextarea.html",
"valueType": "TEXT"
View gist:9189c212e4237882d520
private void PopulatePaging(Stream stream)
const int pageSize = 5;
var skipItems = (pageSize * stream.Page) - pageSize;
var posts = stream.Content.Children.ToList();
stream.TotalPages = Convert.ToInt32(Math.Ceiling((double)posts.Count() / pageSize));
stream.PreviousPage = stream.Page - 1;
stream.NextPage = stream.Page + 1;
View gist:9ac50d5a473ef028725d
<section class="pagination-wrapper">
<nav class="pagination" role="pagination">
@if (Model.IsFirstPage == false)
<a class="newer-posts" href="?page=@Model.PreviousPage">&larr; Newer Posts</a>
<span class="page-number">Page <span class="number">@Model.Page</span> of <span class="number">@Model.TotalPages</span></span>
You can’t perform that action at this time.