Skip to content

Instantly share code, notes, and snippets.

View nul800sebastiaan's full-sized avatar
🔥

Sebastiaan Janssen nul800sebastiaan

🔥
View GitHub Profile
{
propertyEditors: [
{
alias: "My.CustomEditor",
name: "Custom Editor",
editor: {
view: "~/App_Plugins/CustomEditor/customeditor.html"
}
}
],
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)
.NET Framework 4.5 selected
File > New Project > Visual C# > Web > ASP.NET Web Application > Empty
In Package Manager Console, https://nuget.org/api/v2/ 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
After installing http://our.umbraco.org/projects/backoffice-extensions/azure-blob-storage-provider
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.
<smtp deliveryMethod="SpecifiedPickupDirectory">
<specifiedPickupDirectory
pickupDirectoryLocation="D:\Level1MasterclassAugust2014\UmbracoCms.7.2.0-alpha\App_Data\mail" />
</smtp>
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
{
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
package.manifest:
{
"propertyEditors": [
{
"alias": "Long.Textarea",
"name": "Long Textarea",
"editor": {
"view": "~/App_Plugins/LongTextarea/longtextarea.html",
"valueType": "TEXT"
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;
<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>