ActiveTopics Mon, 24 Apr 2017 17:05:25 +00:00 umbraco Latests topics from the forum on en Restrict users from accessing media files using direct links Hi All,

We have a restricted page which requires login/Authentication to access it. On this page we have links to media/pdf files which should be accessed only after authentication but if user has direct links to this files, he/she can access them directly without login.

I want to restrict some user groups from accessing some of media/pdf files without login/authentication.

I have searched on forum and not able to find any similar supporting functionality within Umbraco. There are some paid packages which provides similar functionality but I am looking for free resources.

Any help is appreciated.

Thank you

Ritesh Mon, 24 Apr 2017 14:05:03 +00:00
Bug (?) using DTGE + Nested Content with multiple DocTypes Hi,

maybe I'm wrong, but if I create a DTGE grid editor based on a doctype that uses Nested Content configured to use 2 doctypes, when I insert this new grid editor on a page, the "+" NC button does not work.

If the same doctype based on NC I use for a page property (not grid layout), it works.

If the NC is configured to use only one doctype then it also works with DTGE

To reproduce the issue in local (Windows 10 v1607 build 14393.1066, IIS 10.0.14393.0):

  • download Umbraco zip from Our
  • install umbraco 7.5.13 without any starterkit
  • install Doc Type Grid Editor 0.4.0 package
  • install Nested Content 0.4.0 package

  • create a doc type without a template, named "Test A" (alias "testA") and with only one property (alias "text", datatype "Textstring")

  • create a doc type without a template, named "Test B" (alias "testB") and with only one property (alias "text", datatype "Textstring")

  • create a datatype named "Test Nested Content" with property editor "Nested Content" and Doc Types "Test A" + "Test B" (other setting at default)

  • create a doc type without a template, named "Test Grid Editor" (alias "testGridEditor"), with only one property (alias "testNC", datatype "Test Nested Content")

  • add in grid.editors.config.js

{ "name": "Test NC", "alias": "testNC", "view": "/App_Plugins/DocTypeGridEditor/Views/doctypegrideditor.html", "render": "/App_Plugins/DocTypeGridEditor/Render/DocTypeGridEditor.cshtml", "icon": "icon-wrench", "config": { "allowedDocTypes": [ "testGridEditor" ], "enablePreview": true, "viewPath": "/Views/Partials/Grid/Editors/", } },

  • create a datatype named "Grid layout" with property editor "Grid layout"

  • create a doc type named "Page", with only one property (alias "mainContent", datatype "Grid layout")

  • create a document of type "Page" in content, choose a "1 column layout", add a row "Headline", add a content "Test NC"

By clicking the "+" button to add content, nothing happens.

Am I wrong somewhere?

Thanks, Fabry

Fabry Mon, 24 Apr 2017 13:50:37 +00:00
File GenericProperty.ascx.cs was not found I have upgraded to Umbraco 7.5.13 from 7.1.7 but cannot build the website or update anything using NuGet. I am currently getting the following error messages:

  • File GenericProperty.ascx.cs was not found
  • 'umbracocontrolsgenericpropertiesgenericpropertyaspx' does not contain a definition for 'FullId' and no extension method 'FullId' accepting a first argument of type 'umbracocontrolsgenericpropertiesgenericpropertyaspx' could be found (are you missing a using directive or an assembly reference?)

In the Umbraco.dll file there is only Umbraco.controls, Umbraco.controls.Images and Umbraco.controls.Tree so it looks like I am missing files.

Can someone please help me out on this. It has taken me a week so far to upgrade and I am getting nowhere fast. Thank you.

Webdev Mon, 24 Apr 2017 13:25:43 +00:00
[Grid] Render navigation base on selected grid elements Hello,

I've following requirements:

  • Home page contains Grid with few elements.
  • Home page will be the only Page on the website (One page website ?).
  • Navigation on the header should contain links to some of the elements in the Grid
  • After clicking on the navigation item, site should scroll to the top of appropriate Grid element.

My current solution to this requirements is

  • Add extra property Navigation Title to each of the Grid Editors.
  • I'm using Leblender Editor as Grid Editor
  • If the Navigation Title will be filled then this grid element will qualify to be displayed in the navigation.
  • To get all the grid elements to render I will
    • use the GetPropert(gridAlias) to get the grid
    • Iterate over sections , rows and also areas properties of the Grid Element.
    • If there is a Navigation Title property in value collection and it contains any value, then I will use it to render this in navigation
  • To be able to scroll to given grid element:
    • Add id attribute to the grid elements that have Navigation Title filled in.

Is this solution correct or maybe some of you have better idea how I can solve this problem?

Best regards, Dawid

Dawid Mon, 24 Apr 2017 13:11:31 +00:00
The datepicker (for picking a range) is broken Clicking the datepicker button does nothing.

Edgar Rasquin Mon, 24 Apr 2017 12:22:19 +00:00
Models builder and partials Imtrying to transition from the dynamic @CurrentPage to Strongly typed and Models builder in preperation for V8. I have a question about partials though. Seeing as the models builder is hooked to the document type, how do you go about using the same partial on different doc types? This would often happen, if you use doc type compositions.

For now i have it working by using the same inherits and using on both the template and partial, eg:

@inherits UmbracoViewPage<ContentModels.Home>
@using ContentModels = Umbraco.Web.PublishedContentModels;

But what should i do, if i want to use the partial on the doctype "Textpage" as well as the the "Home" doctype?

Claushingebjerg Mon, 24 Apr 2017 12:01:07 +00:00
promise waiting for AuthTimeout service before it resolves. I'm writing an AngularJS plugin for Umbraco and have created a simple view, controller and service. But for some reason my promise is taking a while to resolve.

I have used the inbuilt $q service to create and return my promise, I have logged out my variables and can see when the async service finishes but there is a noticeable time difference between that and the resolve function being called.

I have since discovered the promise looks like it is waiting for Umbracos GetRemainingTimeout service before it resolves.

Can someone explain why this might be happening?


  .controller('JaywingAnalyticsHelper.ViewController', function ($scope, googleService) {
    googleService.checkAuth().then(function (signedIn){
      $scope.isAuthorised = signedIn;


  .service('googleService', function ($q) {

    var clientId = 'REMOVED_FOR_PRIVACY',
      scopes = [''],
      deferred = $q.defer();

    this.checkAuth = function () {
      gapi.load('auth2', function () {
        gapi.auth2.init().then(function () {
          var googleAuth = gapi.auth2.getAuthInstance();
          var signedIn = googleAuth.isSignedIn.get();
        }, function(){

      return deferred.promise;

Umbraco version - 7.5.12
Angular version - 1.1.5

Stuey Mon, 24 Apr 2017 10:55:38 +00:00
Hitting 'Save' shows modified content on Local. Then what is 'Save and publish'? Hi, I have installed Umbraco on my local machine for practice. Logged in as Admin, when I hit 'Save' to save the content and launch http://localhost:xxxx/, I see the changed content. But I'm expecting to see the changes only after hitting 'Save & Publish'?? Please let me know what am I missing here and why I'm able to see the changed content without hitting 'Save and Publish?

Manas Mathur Mon, 24 Apr 2017 10:37:54 +00:00
Templates do not render using cloud or IIS Hi, I have started and deployed a blank umbraco starter website. I can run and edit the website on local .net express service, however, when I run it from IIS or a deployed version of umbraco, I can edit the website and use umbraco management pages, but the website will not render my templates giving me an error message "No physical template file was found for template Home".

What do I need to do to fix that? I checked the forums, and normally the issue is caused my custom controls. But all my controls are out-of-the-box umbraco starter kit.

Many thanks,


Elvis Mon, 24 Apr 2017 10:11:28 +00:00
Send email from backoffice Please do not suggest newsletter as only sending to 20 people is not an option (as is paying $1000 a year).

I just need to be able to send an email to all the people on a node. I can do this from the front-end, and obviously the backoffice is more than capable of doing this, But there are only a couple of solutions in the backend I could find.

Perplex and Newsletter.

Perplex looks like it is exactly what I want, but I cannot find a send button (excepting the 'test send' button which works exactly as it should)

Am I going to have to make my own plugin to do this?

Damien Holley Mon, 24 Apr 2017 09:28:32 +00:00
Any global variable to tell page is loaded completely I am creating a package which is in jquery. Is there any global watcher or variable which can tell that the page content is loaded completely in content editor. As I cant load all textareas on document.ready because the content template loading is in process.

So can anyone help in this regard, how can we check if complete page is loaded.

Amna Butt Mon, 24 Apr 2017 09:25:56 +00:00
Unlicensed support for localhost I am still developing our system on my local machine. Having just upgraded from v3.1.2 to v3.2.4 I can no longer access the Event calendar section via http://localhost, instead I now get 'Warning! You're running on a trial license of EventCalendar. ' on the Event Calendar tab.

Is localhost still supported for developers? I am not permitted to purchase a domain license until I can demonstrate the Event Calendar package to our web design team which I why I am currently tied to my local machine.

Rob de Mercado Mon, 24 Apr 2017 08:42:44 +00:00
Send the emails from the backoffice Hi, it is obvious that you can send the emails from the backoffice (the test send button) I just wondered if there is a way to send the 'actual' email, not just a test?

I will be using backoffice users AND programmatically through the website to add emails to a subscriber list. This will update the mail node for BCC receivers.

Now I just need the ability for someone in the backoffice to attach the document and hit send, except I cannot find the send button.

Regards, Damien Holley

Damien (Slipoch) Mon, 24 Apr 2017 05:42:36 +00:00
Courier - Content deploy dialogs don't work. Hi - Pretty standard Courier install on an older version of Umbraco. Courier installed okay, set-up target sites okay, can view target sites via the Courier backoffice panel. "bin" folder appears to have all the normal binaries.

However, the Courier Backoffice Revisions tree throws an Exception: Object reference not set to an instance of an object.

And, when attempting to deploy content, I get a Server error (See below).

Can anyone suggest a possible reason for these errors?

Thank you.

Umbraco version 7.2.8 assembly: 1.0.5675.23466

Server Error in '/' Application.

Compilation Error

Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS1061: 'ASP.umbracopluginscourierdialogscommititemaspx' does not contain a definition for 'startDeploy' and no extension method 'startDeploy' accepting a first argument of type 'ASP.umbracopluginscourierdialogscommititemaspx' could be found (are you missing a using directive or an assembly reference?)

Source Error:

Line 223:
Line 224:

Line 225: Line 226:

Line 227:

Source File: c:\Workspace\001-\umbraco\Plugins\courier\dialogs\CommitItem.aspx Line: 225

Compiler Warning Messages:

Show Detailed Compiler Output:

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.6.1637.0

PatP Mon, 24 Apr 2017 03:49:57 +00:00
Check if it value changed from ON to OFF on document save event I have used simple contentservice event handler before to get a value on document save.

What I am wondering is how to go about checking if the field (say True/False field) is changed (from true to false, or false to true) on document save. So I can initiate an email only if the value changed from previous set value.

Would appreciate if someone can shed some light on how to go about this.

keilo Mon, 24 Apr 2017 02:25:51 +00:00
Detect when a node is being saved the first time This is probably obvious, but is there a way to reliably determine when a node is being saved for the first time?

John Bergman Sun, 23 Apr 2017 20:28:11 +00:00
uSync Filepath too long issue (even with use short paths=true) I have a LARGE Umbraco site we are trying to use uSync with, but have issues because even with the setting to use the short paths, we are still only to get 8 or 9 levels deep, and some or our site is 12-14 levels.

Would it be possible to use a different id for at least the content directories, why not just use the contented or node id, instead of a hash, is there a technical reason that it wouldnt work?

I arrived at the 8 to 9 using the following formula.

The hash for the directory is 22 characters (+1 for the path separator) = 23 the content.config files= 13 characters

the config has this "~/usync/data" = 11 characters assuming you publish into a "normal site (c:\inetpub\Umbraco) = 18 characters

this means that 11+13+18 = 42 characters of "fixed overhead"

given that the error is related to 260 characters, minus the overhead means we really only have 218 characters to work with.

218/23 = 9 levels; assuming my math is correct.

John Bergman Sun, 23 Apr 2017 00:44:39 +00:00
UmbracoApiController Session Data with IIS not working I am submitting this post as an act of desperation and hope someone might have some thoughts on the following:

  1. I have an API Controller based on UmbracoApiController that uses and relies on Session variables. (I have a need for this regardless of the fact that it violates REST principles).
  2. I also use Session variables in the my mvc controllers. Umbraco.Web.Mvc.RenderMvcController
  3. When I am developing and running the web site in IIS Express, both of the types of controllers work just fine. I.E. : HttpContext.Session["SOMVEVARIABLE"] works perfectly.
  4. When I move the site to IIS though, the controllers based on the RenderMVC Controller work perfectly as well.
  5. The Controllers based on UmbracoApiController on the other hand have a null Session.

I have searched and searched and have come up empty handed. I am hopeful that someone else has experienced this and might have some suggested work arounds or fixes.

Thank you


Robert Wilchek Sat, 22 Apr 2017 12:54:02 +00:00
Umbraco Create Treeview Context Menu Item - Passing in Value (possible querystring) Hi Guys,

I'm just starting to figure out how to add context menu items to the umbraco backend and then calling some backend controller.

I got the basics down but I want to know if this is possible....

So I created a menu item using the ApplicationStarted event.

private void ContentTreeController_MenuRendering(TreeControllerBase sender, MenuRenderingEventArgs e)
            var item = new MenuItem("exportCsv", "Export to CSV");
            item.AdditionalData.Add("actionView", "/App_Plugins/exportCsv/index.html?nodeTypeAlias=jobClassificationIndustry");
            item.Icon = "save";
            e.Menu.Items.Insert(e.Menu.Items.Count, item);

I want to know if there is anyway I can pass a value into the html file that we have to create in the AppPlugins folder. In my case AppPlugins/exportCsv/index.html

<div class="umbracoDialog umb-dialog">
    <p>Click <em>export</em> to download items to CSV</p>

        alert(window.location.pathname +;

    <div class="umb-dialog-footer btn-toolbar umb-btn-toolbar">
        <a href="/Umbraco/Backoffice/Api/NewsItemExport/Export?nodeTypeAlias=jobClassificationIndustry" target="_blank" class="btn btn-primary">

You can probably see what I am trying to do from the menu item I have created. You can see I tried to add a query string on the end of the menu items. I was hoping I could pass this into the html file and then access this through javascript.

I am guessing there is a better way to do this. Any help understanding how all this works would be much appreciated.

Thanks in advanced :0


David Armitage Sat, 22 Apr 2017 10:22:37 +00:00
SEO Checker throws "BrokenLinks" error when crawling linked in page Umbraco Version: 7.5.13

SEO Checker Version:

I'm encountering the following error when there is a link to a linked in company page (

2017-04-21 09:56:28,819 [P4980/D2/T25] ERROR SEOChecker.Core.Validation.SEOValidator - SEOChecker: Error during validating tag for document: 1052 using validator 'BrokenLinks'
System.ArgumentNullException: Value cannot be null.
Parameter name: format
   at System.String.FormatHelper(IFormatProvider provider, String format, ParamsArray args)
   at SEOChecker.Validators.ContentValidators.Links.BrokenLinkValidator.Parse(ValidationResult result, IUmbracoDocument document, HtmlDocument htmlDocument, IContextInfo contextInfo)
   at SEOChecker.Core.Validation.SEOValidator.Validate(ValidationResult validationResult, IUmbracoDocument document, HtmlDocument htmlDocument, IContextInfo context)

It's not a page that requires authentication, but it may be blocking crawlers to avoid affecting any metrics it's generating. I tried pointing it to and it didn't have any issues with that. This is a problem, as that company link appears on every page. Every time a page node is visited within umbraco, a new error is added to the trace log.

SEO Checker needs a way to handle or ignore this error, as it can knock out a server if the trace logs aren't regularly pruned.

Jesse Andrews Fri, 21 Apr 2017 17:42:58 +00:00
Services.MemberService.GetAllMembers is empty I've found some examples of Services.MemberService.GetAllMembers method usage right in the template. Although for me this is always empty collection. I suspect because currently logged in user could have insufficient access to this kind of information. Does anybody have any suggestions how to allow every user (guest also) to obtain an access to the memberlist?

P.S: I'm using custom membership provider.

Semyon Vyskubov Fri, 21 Apr 2017 16:05:02 +00:00
Upgrading Umbraco 7.4.3->7.5.13 using nuget. Install/api/GetSetup 404 not found!? Hello,

We are using Umbraco, version 7.4.3 in one of our sites. I have spent the day trying to upgrade it to 7.5.13 but I get a strange behaviour.

When the update is complete I run the site on localhost. (I have merged all my config files according to my best knowledge) I enter my credentials and the page is redirected to the install screen with the ukulele and the sofa. However, I get stuck here.

If I open up the developer console in IE I see that the action install/api/GetSetup returns a 404 - not found error.

If I download the source code from github and run it, the install/api/GetSetup is retrieved correctly for that site. But the nuget DLL's in my old site will not resolve the address.

I was thinking that maybe I could finish the database upgrade by entering my database data into that freshly created folder that I just downloaded from github. However, Umbraco will not let me log in using my credentials, even though I point the umbracoDbDSN to my database in the web.config.

So, please advice: 1. Should I even use nuget to upgrade Umbraco? 2. Has anyone got stuck at the same location and knows how to help me get through? 3. Is it possible for me to finish up the database job through my newly created github localhost site? 4. Why can't I log in to the newly created umbraco github localhost site using my existing database connection and the same username/password?

Tomas Heed Fri, 21 Apr 2017 15:15:18 +00:00
Access order in shipping calculator I just upgraded TC from 2.2.3 to 2.3.5. Earlier I did this:

protected override decimal CalculatePrice(ShippingMethod shippingMethod, Currency currency, Order order)
     if (order.SubtotalPrice.WithVat >= 175)
                return 0M;

     return base.CalculatePrice(shippingMethod, currency, order);

But now the signature has changed, so I cant access the order paramter?

protected override Price CalculatePrice(ShippingMethod shippingMethod, Currency currency, long countryId, long? countryRegionId, VatRate vatRate)

Is this not possible anymore or am I missing something?

Tobbe Fri, 21 Apr 2017 13:17:25 +00:00
Design advice on how to OAuth backoffice custom section against 3rd party API Hi,

I'm building a backoffice application/ section that is a tree controller when the trees are clicked I need to authenticate against a 3rd party using OAuth.

So you login normally and can see my new section along with all the others, when you start clicking the tree controller nodes it starts using the 3rd party API which requires OAuth.

What would be the best way of implementing OAuth for my new custom section?

I was thinking of pushing it into the angular controllers put I'm struggling with the return URL. I also need a way that if the API fails because of a expired token to then go back through the process.

I was thinking of letting all my tree nodes redirect to a authenticate view:


which would direct me to


here I'd call out to the 3rd party with a Ajax post.

If successful, I'd then redirect to the normal view with access to the token. However it's the return URL I'm struggling with..

Anyone attempted anything like this?

The other idea would be to hijack the normal login process and add the OAuth to that. So a user logging in would have to be successful with the normal umbraco login and the 3rd party OAuth.

Guess I'm just looking for a little guiding and I'll try and run with it. I'm at a stage that I don't want to go down a path for 2 weeks and it just not be possible.

Any ideas or reply's would be great

Thanks Rob

Rob Carlaw Fri, 21 Apr 2017 13:08:23 +00:00
Project SetUp I was trying to setup an old project in my VS13 and i was unable to complete the setup because of the following issue.

A help will be much appreciated. enter image description here

Abhishek Pokhrel Fri, 21 Apr 2017 10:54:06 +00:00
Date picker in front page and japanese characters Hi,

I have a an issue with the date picker in my form, when I select a date it's set with japaneses characters are add in the field : enter image description here

I searched in the forum a same issue but I found nothing else about it. Do you have an idea of the problem ? I am using Forms "4.4.2".


Sylvain Roques Fri, 21 Apr 2017 10:12:42 +00:00
ERROR Umbraco.Core.UmbracoApplicationBase - Unhandled exception in AppDomain (terminating) Hello.

using Umbraco version 7.5.4 and uCommerce version and Newsletter Studio version 2.1.5.

In one of our webapplications we are getting this error, and it shut down the application.

[P4828/D2/T2] ERROR Umbraco.Core.UmbracoApplicationBase - Unhandled exception in AppDomain (terminating)
System.NullReferenceException: Object reference not set to an instance of an object.
   at log4net.Appender.RollingFileAppender.AdjustFileBeforeAppend()
   at Umbraco.Core.Logging.AsynchronousRollingFileAppender.OnClose()
   at log4net.Appender.AppenderSkeleton.Close()
   at log4net.Appender.AppenderSkeleton.Finalize()

Maybe its related to this? ->

I have started 2 threads because i think its 2 different problems.

Bo Jacobsen Fri, 21 Apr 2017 08:04:05 +00:00
ERROR Umbraco.Core.Dynamics.ExtensionMethodFinder - Failed to get types. Hello.

using Umbraco version 7.5.4 and uCommerce version and Newsletter Studio version 2.1.5.

In one of our webapplications we are getting this error ,from time to time:

[P10028/D3/T50] ERROR Umbraco.Core.Dynamics.ExtensionMethodFinder - Failed to get types.
    System.Reflection.ReflectionTypeLoadException: Could not load all types from "Spatial4n.Core.NTS, Version=, Culture=neutral, PublicKeyToken=9f9456e1ca16d45e" due to LoaderExceptions, skipping:
    . System.IO.FileNotFoundException: Could not load file or assembly 'GeoAPI, Version=1.7.4693.18483, Culture=neutral, PublicKeyToken=a1a0da7def465678' or one of its dependencies. The system cannot find the file specified.
    . System.IO.FileNotFoundException: Could not load file or assembly 'GeoAPI, Version=1.7.4693.18483, Culture=neutral, PublicKeyToken=a1a0da7def465678' or one of its dependencies. The system cannot find the file specified.
    . System.IO.FileNotFoundException: Could not load file or assembly 'GeoAPI, Version=1.7.4693.18483, Culture=neutral, PublicKeyToken=a1a0da7def465678' or one of its dependencies. The system cannot find the file specified.

       at Umbraco.Core.TypeFinder.GetTypesWithFormattedException(Assembly a)
       at Umbraco.Core.Dynamics.ExtensionMethodFinder.GetTypes(Assembly a)

Maybe its related to this? ->

I have started 2 threads because i think its 2 different problems.

Bo Jacobsen Fri, 21 Apr 2017 08:00:53 +00:00
Preview PDF files as images on your website Hi all,

I've found this neat article of Damiaan on his blog about displaying PDFs as an image on your website.

Damiaan already informed me that I can donwload the nuget file and extract it by changing the extension to .zip. Then you only need to add the DLL files to the /bin folder.

But now how can I integrate this in my website directly from within Umbraco? (So without using Visual Studio).

Thanks and kr,


Laurens Gregoir Wed, 19 Apr 2017 13:53:34 +00:00
Getting umbracoFile property within a ModelBuilder model Hi,

after a looong pause, I'm trying to get back at Umbraco in the "right way" (tm)...

I have created a "File Media" Document Type with a Media Picker property called "Allegato" and I want to override the Url property of the model generated by ModelBuilder in order to return the file media Url (i.e. the "umbracoFile" property of the Media Picker).

Up to now this is the best solution I have found:

 public partial class FileMedia
    public override string Url
                int allegatoID = Int32.Parse(this.Allegato);
                var mediaService = ApplicationContext.Current.Services.MediaService;
                var allegatoMedia = mediaService.GetById(allegatoID);
                return allegatoMedia.GetValue("umbracoFile").ToString();
            catch (FormatException e)
                return base.Url;

but it uses ApplicationContext.Current property, which should not be done as explained in Common Pitfalls.

Is there a better way?

Thanks, Marco

Marco Lusini Wed, 19 Apr 2017 10:21:35 +00:00
Invoice items missing in second order Hi!

I'm setting up a simple webshop using Umbraco and Merchello for the first time. For now, the checkout is made in one step where the anonymous customer enters shipping- and billing information in a form and just confirms the order.

Everything works great the first time I complete the checkout process. However, if I then go back to the products page, add a few items to the basket and then try to checkout again the items are never added to the invoice. Only shipment rate and a tax item with value 0 is added. Is this something related to caching or am I just missing something in the checkout-process?

Here is my Checkout action:

    public ActionResult Checkout(CustomerInfoViewModel model)
        if (!ModelState.IsValid)
            return CurrentUmbracoPage();

        var checkoutManager = Basket.GetCheckoutManager();

        //Create adresses
        var billingAddress = new Address
            Name = model.BillingName,
            Address1 = model.BillingAddress,
            PostalCode = model.BillingZipCode,
            Locality = model.BillingCity,

        var shippingAddress = new Address
            Name = model.Name,
            Email = model.Email,
            Address1 = model.Street,
            PostalCode = model.ZipCode,
            Locality = model.City


        //Set billingadress
        if (!string.IsNullOrEmpty(billingAddress.Address1) &&
            !string.IsNullOrEmpty(billingAddress.PostalCode) &&

        //Set shippingaddress

        var shipment = Basket.PackageBasket(shippingAddress).FirstOrDefault();
        if (shipment != null)
            //Create invoice
            var invoice = checkoutManager.Payment.PrepareInvoice();

            //Add shipment to invoice
            var shipmentRateQuotes = shipment.ShipmentRateQuotes().ToList();
            if (shipmentRateQuotes.Count > 0 )

        var paymentMethod = MerchelloContext.Current.Gateways.Payment.GetPaymentGatewayMethods().FirstOrDefault(p => p.PaymentMethod?.Name == _paymentMethod);
        if (paymentMethod != null)
            var payment = checkoutManager.Payment.AuthorizePayment(paymentMethod);
            //var payment = invoice.AuthorizePayment(paymentMethod);
            if (payment.Payment.Success)
                //Add note to invoice if anything to add
                if (!string.IsNullOrEmpty(model.Message))
                    var invoiceAgain = MerchelloServices.InvoiceService.GetByKey(payment.Invoice.Key);
                    if (invoiceAgain != null)
                        var note = MerchelloServices.NoteService.CreateNote(invoiceAgain.Key, EntityType.Invoice, model.Message);
                        note.CreateDate = DateTime.Now;
                        note.InternalOnly = false;
                        note.Author = shippingAddress.Name;

                        invoiceAgain.Notes = new List<INote> { note };


                        //Must re-save the invoice to add the note

                Notification.Trigger("OrderConfirmation", payment, new List<string>{ model.Email });

                //Store invoiceKey on Customer for reciept generation
                CustomerContext.SetValue("invoiceKey", payment.Invoice.Key.ToString());

        return RedirectToCurrentUmbracoPage();

Any help would be very appreciated! :)

Gustav Malmström Mon, 17 Apr 2017 07:55:45 +00:00
Umbraco Core or Umbraco Rest API? Hello,

Being new to Umbraco, it's really confusing to understand when to use Umbraco code binaries and when to use Umbraco Rest API.

Our requirement is as follows. We are building an Umbraco website. Along with the pages for the website, the email templates, that will be sent to customers on various occasions, will also reside in Umbraco. These templates will be used to send an email to the customer when they complete certain actions on the website. So far so good.

We also have another bespoke .NET MVC application which will be used by administrators. If a customer contacts them and says they didn't receive a confirmation or an email for something they did on the website described above, the administrators need to have the ability to send that email to the customer. To do that, they need to retrieve the HTML output from the Umbraco Razor template, substitute placeholders with customer data and send the email. To achieve this functionality, we want to develop ASP.NET Web API that this bespoke MVC application can talk to to retrieve the email HTML body. The Web API should query the Umbraco website and return the email template HTML output.

How do I achieve this:? Should I use Umbraco core binaries in the Web API and try to get the output or should I use Umbraco Rest API to retrieve? Has anyone done something like this before? If so please could you provide code samples?

There aren't many code samples for the Umbraco Rest API so it's hard to comprehend under what circumstances they should be used.

Please help. Thanks.

Meenakshi Ravi Wed, 12 Apr 2017 14:44:28 +00:00
Administration screen for a plugin package Is it possible to have an admin screen against my package in Umbraco. Like we usually have in wordpress against plugins.

I wanted to show a menu for my plugin in right section of Umbraco, which opens an interface where developer can add License key and other required information.

Any help in this regard would be great as I cannot find any link/tutorial to make this happen

Amna Butt Wed, 12 Apr 2017 05:51:32 +00:00
An unexpected network error on Azure Web Apps Hi,

Overnight one of our websites started to crash permanently, it is running on version 7.5.11 and we are hosting it on Azure Web Apps.

The error message says:

Exception type: IOException Exception message: An unexpected network error occurred. at Umbraco.Core.Cache.HttpRuntimeCacheProvider.GetCacheItem(String cacheKey, Func1 getCacheItem, Nullable1 timeout, Boolean isSliding, CacheItemPriority priority, CacheItemRemovedCallback removedCallback, CacheDependency dependency) at Umbraco.Core.Cache.HttpRuntimeCacheProvider.GetCacheItem(String cacheKey, Func1 getCacheItem, Nullable1 timeout, Boolean isSliding, CacheItemPriority priority, CacheItemRemovedCallback removedCallback, String[] dependentFiles) at Umbraco.Core.Cache.DeepCloneRuntimeCacheProvider.GetCacheItem(String cacheKey, Func1 getCacheItem, Nullable1 timeout, Boolean isSliding, CacheItemPriority priority, CacheItemRemovedCallback removedCallback, String[] dependentFiles) at Umbraco.Web.PublishedCache.XmlPublishedCache.PublishedMediaCache.GetCacheValues(Int32 id, Func2 func) at Umbraco.Web.PublishedCache.XmlPublishedCache.PublishedMediaCache.GetUmbracoMedia(Int32 id) at Umbraco.Web.PublishedCache.XmlPublishedCache.PublishedMediaCache.GetById(UmbracoContext umbracoContext, Boolean preview, Int32 nodeId) at Umbraco.Web.PublishedCache.ContextualPublishedCache1.GetById(Boolean preview, Int32 contentId) at Umbraco.Web.PublishedContentQuery.DocumentById(Int32 id, ContextualPublishedCache cache, Object ifNotFound) at Umbraco.Web.PublishedContentQuery.Media(Int32 id) at Umbraco.Web.UmbracoHelper.Media(String id)

The media file exists, and republishing the home node brought the site back online.

Has anyone experienced something similar, or any ideas what the root cause is?

Thanks, Rachel

Rachel Thu, 06 Apr 2017 09:20:33 +00:00
URL slug not an exact match Let's say I have two products with the url slugs:

Product 1: /my-product


Product 2: /my-product-extra

If I browse to I cannot be certain which product will actually be displayed. This seems to be an issue in

Merchello.Web.Search.CachedProductQuery.GetBySlug(string slug)

This code searches for the slug in the index but does not do an exact match. This appears to be a limitation/feature of Lucene I believe, not a Merchello issue. The index returns all matches (even partial as its Lucene) and the Merchello code does a FirstOrDefault so you get the product that is first in the index. this now a problem for Merchello users? It was certainly an issue for me. I have solved the issue by creating my own IContentFinder which is based on GetBySlug but gets all Lucene matches. I then iterate through them manually looking for the exact match and then get that product from Merchello using it's SKU.

I would be a happy to add this logic to Merchello.Web.Search.CachedProductQuery.GetBySlug(string slug) and do a pull request. It's only a few lines. But before I do, is this a required change or is the current partial match acceptable by design?

Kevin Mon, 27 Mar 2017 12:25:25 +00:00
404 errors on some pages using https I am testing our new site on https, and find that certain pages occasionally show as 404 not found. It only happens for some pages, and sometimes I get the correct page and sometimes I get the 404 page. If I disable https the pages all work again, but we want production to be using https.

Enabling Failed request logging in IIS I get the following:


OldUrl /search?query=rome
NewUrl /umbraco/RenderMvc?query=rome

OldUrl /umbraco/RenderMvc?query=rome
NewUrl /search?query=rome


ModuleName: UmbracoModule 
Notification: 8 
HttpStatus: 404 
HttpReason: Not Found 
HttpSubStatus: 0 
ErrorCode: 0 
ErrorCode: The operation completed successfully. (0x0)

any idea on how to investigate this issue further, or suggestions on possible cause, as I am a bit stuck

andrew darby Tue, 21 Mar 2017 18:25:42 +00:00
Error logging into Umbraco via localhost Having some issues accessing the Umbraco back-end on my local copy of the project. I have a hosted version of the project, connected to the same database, and although both load the website fine, logging into the back-office only seems to work on the hosted version. My local version (where everything was set up originally) throws a 400 "Invalid creds" whenever I try logging in, despite the username/password being the same as the ones I can use to log in on the hosted version.

Just looking for some suggestions on where to start with this if anyone has any ideas. If there's any additional information I can provide that might be helpful, just let me know. :)

Daniel McAteer Tue, 21 Mar 2017 16:46:29 +00:00
Umbraco 7.6 feedback Hi Everyone!

As you might have noticed, we've released the beta of Umbraco 7.6 - full details here. We'd love feedback and the more we get the faster it'll go from Beta to Release.

For general feedback use this forum post, but for specific bug reports, please use the issue tracker.

Niels Hartvig Mon, 20 Mar 2017 12:27:55 +00:00
wordpress in a sub folder /blog gives 404 not found error I have read previous threads about installing a separate application within a subfolder, but I did not find a solution that worked.

This is a short term requirement until we implement and migrate content to an umbraco blog.

Using Umbrac 7.4.3 I have added /blog/ and /blog to the web.config

and the blog folder is setup as its own application.

When I browse to I get redirected to our sites 404 page

Enabling Failed Request logs in IIS, I get the details as below: If anyone has this working with version 7 - would appreciate any further tips.


ModuleName UmbracoModule

Notification 8


HttpReason Not Found

HttpSubStatus 0

ErrorCode 0



ErrorCode The operation completed successfully. (0x0)

andrew darby Mon, 27 Feb 2017 17:44:07 +00:00
No providers available Hi,

I tested this using Umbraco 7.5.9 and 7.5.0. I installed Terratype via Nuget: Install-Package Terratype Afterwards, I installed Google Maps: Install-Package TerraType.GoogleMapsV3 Both installations were successful.

Once I tried to create my datatype, it said: No Terratype map providers have been installed. Please read the documentation for details on how to install providers

I can see both folders for TerraType and Terratype.GoogleMapsV3 on the App_Plugins folder. Is there anything else I should do? Already did a rebuild on the solution. But nothing happened.


enter image description here

enter image description here

Francielle Tue, 07 Feb 2017 16:41:42 +00:00
newest fa libs can I copy in the newest font-awesome libs, overwriting your packaged files? I see there is what looks like a custom fa-umbraco.css file...

Max Wed, 04 Jan 2017 15:25:18 +00:00
Send mail maketing in backoffice Umbraco Hi all!

I have a list email in backoffice( list mail subcribe). Now I would like to email this mailing list.

I need to help. Thank all!

Tôn Trưởng Mon, 05 Dec 2016 04:27:15 +00:00
Saving and Publishing a Node with the ContentService moves it 1 level up the tree I'm using the ContentService and MediaService to create a new IMedia, and then update a property on an existing IContent with the new IMedia's ID and publish the changes.

Here's my code (more or less):

var existingContentNode = _contentService.GetById(contentNodeId);

var newImage = _mediaService.CreateMedia(newImageFileName, newMediaParentNodeId, "image");


existingContentNode.SetValue(imagePropertyAlias, newImage.Id);


The image is always created and set, which is the desired behaviour. However, roughly half the time this code has an undesired side-affect and moves the existing content node one level up the tree, becoming a sibling of (what was) it's parent.

I am unable to reproduce this on my local machine; this issue is only happening on the server.

Further Information

Umbraco version 7.4.2 assembly: 1.0.5921.28477

I also have Ditto v0.8.4, uSync v3.2.0.740, and Chauffeur v0.6.4 installed (via NuGet).

The dependencies on IMediaService and IContentService are being resolved by a DI container, Autofac v3.5.2 with the following code:

var builder = new ContainerBuilder();
// ... 


// ...

Thanks in advance,


Gary Cheetham Thu, 20 Oct 2016 11:49:12 +00:00
Klarna Checkout integration Hi,

I'm trying to integrate Klarna Checkout ( with Merchello, and I've run into a major issue.

Klarna Checkout handles the entire checkout process through iframed forms, and I've implemented a custom PaymentMethodUiController that handles this, taking advantage of the resolvable payment form feature in Merchello.

Due to the way Klarna Checkout is designed, we can't create an order/invoice until we've received a confirmation from Klarna (after the customer confirms the purchase). This is done through an HTTP POST request to a special push URL that we've configured earlier.

The problem, however, is that Merchello's checkout flow uses the merchello cookie to identify the customer, and there is no such cookie in the request when we receive the confirmation via the push URL. This means that there is no customer info from the previous steps in checkout flow when we try to create the order (using BasketCheckoutPaymentManager.AuthorizePayment()), causing the CheckoutPaymentManagerBase.IsReadyToInvoice() to return false.

According to Klarnas dev support order creation must take place in the push URL endpoint, so moving it to an earlier step when the merchello cookie is available is not an option either.

Since we have access to the Klarna order ID one possiblity could be to store all the customer info in a temporary DB using the order ID as key and somehow populate the customer context right before we attempt to create the order?

Or is there a better solution? Has anyone else had any experience with implementing Klarna Checkout?

William Zhang Sat, 02 Jul 2016 15:39:10 +00:00
Digital products checkout flow Hi,

We're using Merchello 2.1.0 and have some simple questions regarding digital products.

We figured this would be easy but can't seem to get it straight

  1. All of our products are digital / non-shipable items
  2. Because of this, we skip the shipping step
  3. We're trying to automatically fulfill the order (we auth and capture the full amount but can't seem to set a fulfillment status)
  4. We aren't presented with a fulfillment option in the back end

Our questions

  1. Since these products are digital we do not need to set a shipping method, correct? Or do we need to setup a digital shipment option and automatically set this?
  2. Is there a way to programatically set the fulfillment status to fulfilled?
  3. To mark the product as digital and shippable, we checked the followingn options in Merchello - "this variant has digital goods" and "this variant is available to purchase", we left "this variant is shippable as unchecked and Choose Media as empty - our product isn't a stored digital file. Is anything wrong with this setup?

Any advise would be greatly appreciated.


Zac Sat, 25 Jun 2016 06:11:59 +00:00
Most viewed page - any way to get this data? Hi,

I want to display a list of most view links.

Can this be done in Umbraco 7 easily? I assume it would involve some type of counter.

I saw stuff stuff using xslt but I don't think it xslt is used in V7 is it? Or can it be?

Thanks a lot!

Damon Wed, 22 Jul 2015 16:07:03 +00:00
List view tab name Hi 

I just found the great listview in umbraco 7.

How  do i change the name from "Child items" to eg "Variants"?

I have searched for it, and i cant figure out where.


René Mon, 29 Sep 2014 10:54:49 +00:00
RTE - unwanted 'borders' as a result of auto resize I'm running into a quite annoying issue when my customer started using images in the RTE.

After publishing, unwanted black 'borders' are added. I assume, as a result of the auto resize within the RTE.

Umbraco version: 7.1.1

Just after adding an image it looks like this:

looks fine

After reloading the page, it looks like this:

unwanted border

And also in the frontend it looks like this:

enter image description here

I did some searching and I ran into this: Except when I try to modify the file I don't see my changes getting reflected. I did touch the web.config, so the application is restarted.

and I ran into this unsolved issue:

Currently I unfortunately don't have a solution for this issue. Anyone else ran into this problem? How did you solve it? / work around it?

Roel Snetselaar Mon, 23 Jun 2014 23:02:08 +00:00
dialogService - define startnode Hey

I'm trying to open a dialog that lists the children of a certain node. Heres some code:

                        multiPicker: false,
                        startNode: {
                            id: 4217 //not working

                        callback: function (data) {
                               //bla bla

How do i define the startnode?

Or how do i just list all content of a certain type?

Tom Mon, 19 May 2014 10:36:24 +00:00
How do I check if a property value has changed when saving in API? Hello all.

I am currently working on a V4 event to stop certain umbraco user roles from changing the value of a property of a particular document type.

Here is the code I currently have so far

void Document_BeforeSave(Document sender, SaveEventArgs e)
//GET the current user logged into umbraco
User currentUser = umbraco.helper.GetCurrentUmbracoUser();

if (currentUser.UserType.Alias == "protoEditor")
//WE ARE THE protoEditor type

//Check IF the groupName property's value has been changed
if(sender.getProperty("groupName").VersionId != ..?..)
//Lets set the value back to it's original value
sender.getProperty("groupName").Value = "";

I need some help with the IF and how to set the value back to it's original value.


Warren Buckley Thu, 09 Apr 2009 13:53:01 +00:00