Lemoon 4.5.0 is released

Monday, March 12, 2012 2:36 PM release notes

This is a large release that improves routing and url generation and provides even better SEO techniques such as 301-redirects etc. Lemoon has also been upgraded to target the .NET 4 framework, and all external libraries have been updated to their latest versions.


  • Better slug generation for non alpha characters.
  • Overloads for ContentService.Get, Insert, Update that does not check permissions.
  • Improvements to the Url() extension method.
  • Upgrade to .NET 4 and MVC3.
  • Support for Robots META tag.
  • Support for bindings with internationalized domain names.
  • Support for google-site-verification META tag for Google Webmaster Tools.
  • New html5 project template based on twitter bootstrap.
  • By default, urls should always contain the full path, e.g. /about/contact instead of /contact.
  • Clearing the slug field should generate new slug.
  • Ability to set status codes for alias, e.g. HTTP 301 Moved Permanently.
  • Setting for content type indicating if content should be accessible via url (IsRoutable).
  • Upgrade to TinyMCE 3.4.9.
  • Path/Virtual directory support for site bindings, e.g. www.mysite.com/en/.
  • Switch from log4net to NLog.
  • Setup optionally creates sample content, i.e. populates the site with content items for home, news, about, contact, search, 404 and 500.
  • Distribute Lemoon as a Visual Studio .vsix project template.


  • The robots.txt file is not valid according to Google Webmaster Tools.
  • Fileupload broken in Firefox 7+.
  • ContentService.GetAll(int languageID) returns content from all sites.

Deprecations and breaking changes

The following classes, methods and properties have been marked obsolete and will be removed in future versions of Lemoon.

  • Mindroute.Lemoon.Web.UI.WebControls.RenderForm is Obsolete. Build your own control for saving form results or use the control from the Lemoon Visual Studio Template.

The following classes, methods and properties have been removed.

  • Content.Path has been removed
  • ContentService.GetBySlug(string slug) has been removed, use ContentService.Get(string slug) instead.
  • ContentHelper.Url(bool includePath) has been removed
  • ContentHelper.Url(bool includePath, bool includeHost) has been replaced with ContentHelper.Url(bool absolute).
  • SiteService.GetBindings(int siteID, int languageID) has been removed.

The following breaking changes have been made in this release. After upgrading you need to recompile your solution and fix any compilation errors.

  • Lemoon 4.5 requires SQL Server 2008 or greater (express editions are also supported).
  • Urls to files in the filarchive without the /file/ prefix will no longer work. You will need to manually update any content that use these deprecated urls.
  • The logging library log4net has been replaced with NLog so you may have to modify your existing code if you depended on log4net for logging.
  • The property Content.Aliases now returns a list of Alias instead of a list of strings.
  • ContentService.Get(string slug) only returns content items with a matching slug, previously content items with a matching alias were also returned.
  • Content.Slug is no longer a required property and is not used to map content items to urls. Permalinks and Aliases are used instead.

Upgrading from version 4.5.0

  1. Backup your database and site before performing the upgrade!
  2. Replace your /Admin folder with the contents of the corresponding folder in the upgrade package, but do not touch the /Admin/apps folder which may contain custom code.
  3. Replace your /App_Data/Lib folder with the contents of the corresponding folder in the upgrade package. Update the references in your project to include all files in the App_Data/Lib folder.
  4. Run the SQL script Upgrade-1.4.2-to-4.5.0.sql.
  5. Upgrade your project (and application pool) to target .NET Framework 4 instead of .NET Framework 3.5.
  6. Manually merge your web.config file with the one in the upgrade package.
  7. Change all calls to the extension method Content.Url(true) to Content.Url()
  8. Change all calls to the extension method Content.Url(true, true) to Content.Url(true)
  9. Change all calls to ContentService.GetBySlug() to ContentService.Get()
  10. Update deprecated file urls without the /file/ prefix in content.
  11. Rebuild your solution and fix any compilation errors.