You are browsing the archive for Orchard.

by Editor

So what’s new in Orchard 1.3?

October 5, 2011 in Articles, ASP.NET, News, Reference

Orchard 1.3 was released yesterday night with some really neat features that I will outline in this post. I will come back in depth on some of those with full-length posts. Let's start with the simple but super-useful ones… 1. Draft Preview Once you've created and saved a content item, there will now be a "Preview" link next to its summary: Previously, it was impossible to view unpublished contents. This was one of the most requested missing features, and there it is. 2. Delete Content Types and Parts Speaking about features high on the wish list, you can now delete the custom content types and parts that you built. 3. Markdown Not everyone likes editing contents in Wysywyg editors, for various reasons. There has always been…(read more)

by Editor

PIX-6T4, the DIY console, has an Orchard site

September 18, 2011 in Articles, ASP.NET, News, Reference

If you're a regular reader of this blog, you may have noticed the electronics posts lately. With my friend Fabien , we've been building a little handheld console from readily available parts. It's also programmable in C#, using a library that we built . It's great fun really. Our plan is to build a kit and a book out of it, to help people learn the basics of digital electronics and C# programming. We've built a site for the project over a few nights last week, using Orchard and hosting on Azure . I thought I'd throw in a little return on experience and talk about the modules we used. The site can be found here: http://www.pix6t4.com The first thing I did to build the site was to build the theme. I started from the built…(read more)

by Editor

So you don’t want to use placement.info?

August 1, 2011 in Articles, ASP.NET, News, Reference

In Orchard, the UI gets composed from many independent parts. We wrote a lot of code to handle that fact without friction. It is easy to add a new part or remove an existing one without breaking anything. One ingredient in this is the placement.info file . The role of placement is to dispatch the shapes that represent content types to local zones and to specify in what order they should appear. it separates the templates and their orchestration, implementing some healthy separation of concerns. It is quite powerful and flexible, but it represents a sort of inversion of control that can be quite puzzling to designers: we are used, in other systems, to the layout pulling the different "includes" that constitute it. With placement, the…(read more)

by Editor

Future Orchard Part 3: Autoroute

July 31, 2011 in Articles, ASP.NET, News, Reference

The way URLs work in Orchard today is fine for the simplest sites but it's not very customizable and comes with a number of challenges. Let's look at how it works today. Let's start with a plain page: Once you're done typing a title, when you tab out of the title field, an ajax request is fired that asks the server to do a fake publication of the page and get a slug out of the title. This happens in the Routable part, and it is extensible by implementing ISlugEventHandler. There are a few problems with this. First, the fake publication is creating some noise for subscribers to the publication event. It would be better unfortunately to do away with the nice ajax behavior. Second, it becomes really hairy once you introduce containers…(read more)

by Editor

Future Orchard Part 2: more Tokens

July 27, 2011 in Articles, ASP.NET, News, Reference

This is part 2 for this post … Before I show some more advanced features of Tokens, I should probably say a word about why exactly we think we need this feature. In a CMS, there are many places where you need to build strings from some static but configurable part and a number of values that come from the environment. In the first post in this series , I used the rather silly example of Mad Libs because I thought it was a fun and light-hearted way of explaining the technology. But obviously we are not building the feature to play silly word games, we are building it because we need it to build other cool stuff. Real applications include: e-mail formatting : this does not require full templating but always involves inserting values from various…(read more)

by Editor

Future Orchard Part 1: Introducing Tokens

July 22, 2011 in Articles, ASP.NET, News, Reference

After a long phase of cleanup on the new Orchard 2.0, we are now busy designing new features. We are focusing on a few foundational pieces, and on enabling e-commerce on top of the platform. In this post, I'm going to expose the basics of the preliminary design for one new foundational piece: Tokens. You could technically confuse Tokens with a fancy String.Format, or with a very lightweight templating solution, but you'd be slightly wrong in both cases. Its usage is what sets it apart from both. You will use tokens whenever you need to build a string by inserting named environmental variables into a string that has placeholders. That is it. No code, no loops, no ifs, just formatted substitution, but really the keyword here is environmental…(read more)

by Editor

So what are zones really?

July 1, 2011 in Articles, ASP.NET, News, Reference

There is a (not so) particular kind of shape in Orchard: zones. Functionally, zones are places where other shapes can render. There are top-level zones, the ones defined on Layout, where widgets typically go, and there are local zones that can be defined anywhere. These local zones are what you target in placement.info . Creating a zone is easy because it really is just an empty shape. Most themes include a helper for it: Func<dynamic, dynamic> Zone = x => Display(x); .csharpcode, .csharpcode pre { font-size: small; color: black; font-family: consolas, "Courier New", courier, monospace; background-color: #ffffff; /*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd…(read more)

by Editor

Creating shapes on the fly

June 30, 2011 in Articles, ASP.NET, News, Reference

Most Orchard shapes get created from part drivers, but they are a lot more versatile than that. They can actually be created from pretty much anywhere, including from templates. One example can be found in the Layout.cshtml file of the ThemeMachine theme: WorkContext.Layout.Footer .Add(New.BadgeOfHonor(), "5" ); .csharpcode, .csharpcode pre { font-size: small; color: black; font-family: consolas, "Courier New", courier, monospace; background-color: #ffffff; /*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd { color: #0000ff; } .csharpcode .str { color: #006080; } .csharpcode .op { color: #0000c0; } .csharpcode .preproc { color: #cc6633; } .csharpcode .asp { background…(read more)

by Editor

Adding RSS to tags in Orchard

June 24, 2011 in Articles, ASP.NET, News, Reference

A year ago, I wrote a scary post about RSS in Orchard . RSS was one of the first features we implemented in our CMS , and it has stood the test of time rather well, but the post was explaining things at a level that was probably too abstract whereas my readers were expecting something a little more practical. Well, this post is going to correct this by showing how I built a module that adds RSS feeds for each tag on the site. Hopefully it will show that it's not very complicated in practice, and also that the infrastructure is pretty well thought out. In order to provide RSS, we need to do two things: generate the XML for the feed, and inject the address of that feed into the existing tag listing page, in order to make the feed discoverable…(read more)

by Editor

Orchard 1.2 Released

June 15, 2011 in Articles, News, Reference

Version 1.2 of Orchard is now officially available. You can find the download and release notes here: http://orchard.codeplex.com/releases/view/65184 This release is mainly about bug fixes and performance improvements, but it is also introducing a couple of nice features. Creation date is now the date that we use for everything in the front-end, which should bring [...] Read More……(read more)