Our blog contains the activity stream of Orchard Dojo: general news, new resources or tutorials are announced here.

Content Tree Module, Orchard Core Admin UI experience renewal survey - This week in Orchard (06/06/2025)

This time, you can see a fascinating demo of the Content Tree Module! But first, let's look at our other topics, like adding GraphQL support for querying content items by status from the Content Picker Field, fixing binding form input in the Coming Soon theme, and improving the Register User Task. Don't forget to fill out our Orchard Core Admin UI experience renewal survey to help shape the future of Orchard Core!

Featured tags

IIS
API
SMS
SEO
MCP
All tags >

Error Log Watcher in Lombiq Orchard Visual Studio Extension, Disable and Enable Tasks - This week in Orchard (03/04/2020)

New tasks when working tenants in your workflows, a best practice about how to validate your ViewModel using a service and a spectacular and fun demo about a nice addition to our Orchard Visual Studio Extension! Read our current post for more! Orchard Core updates Tenant Workflows: Disable and Enable Tasks Now you have workflow tasks to Disable or Enable tenants to support tenant management using with Forms or any external services. With these you have four events to manipulate tenants: Create Tenant Enable Tenant Disable Tenant Setup Tenant From now, you can use the workflows to create, setup and then enable the tenants, because we have tasks to cover the whole process. In our case, we created a workflow called Add tenant and used these activities to fire up a tenant from scratch by the values provided by the users in a form. Search inputs Antoine Griffard updated all the search inputs in admin to use autofocus and type="search". This is a way to let the browser display these inputs with better hints. You can even predefine a list of common search inputs if you want. It's not used here, but we could also extend these to do that or show a list of historical data that you put in that textbox. Validating ViewModels We would like to mention this because by reading this solution you could get a nice best practice about how to validate something with a service if you are in a ViewModel. In this current issue, we would like to validate the value of an email address by using the RegisterExternalLoginViewModel. If you would like to validate an object using a ViewModel, you have to implement the IValidatableObject interface which will give you a Validate method. And in this method, you can use whatever service you want. When you create a new instance of your ViewModel, you can pass your service to it in a parameter by using constructor dependency injection. In this current example, we could see the passing of the IEmailAddressValidator to the RegisterExternalLoginViewModel. And in the RegisterExternalLoginViewModel you can use the service in the Validate method injected using the constructor. But, if you see the changes below, you could notice that by using the ValidationContext, you can get your service from the IServiceProvider by calling validationContext.GetService<T>(). In this case, you don't have to pass anything using the constructor when creating a new instance of your ViewModel, just simply resolve your service using the ValidationContext. A new section in the Orchard Core documentation: Resources Now when you open the documentation of Orchard Core, you will find a new item on the menu, called Resources. The goal of the Resources page is to collect any external resources that are available to teach you how to develop with Orchard Core. Our Orchard Core Training Demo module has been added as the first demo project for this page. And you can also found some lines about our newsletter here and the URL where you can sign up for our newsletter! New favicon for the Orchard Core documentation If you check the previous screen again, you will see that the snip contains the title bar of the window too. That's because when you visit the documentation page of Orchard Core, you will face a new blueish favicon, that looks nicer in a browser that uses a darker theme too. Demos Adding BlinkStick support to Lombiq Orchard Visual Studio Extension Orchard Error Log Watcher feature Lombiq Orchard Visual Studio Extension is a Visual Studio extension with many features and templates frequently used by Lombiq developers. It contains Orchard-related (including Orchard Core) as well as generic goodies. This extension has an Orchard Log Watcher feature, that alerts you when you have any new entry in the log file. When you install this extension, you will see a new button on the Orchard Log Watcher toolbar. The button of this toolbar will be enabled when you have unread entries in the error log files. If you click on this button, the log file will be opened with the editor assigned to open .log files. When you navigate to Tools -> Options -> Lombiq Orchard Visual Studio Extension -> Orchard Log Watcher you can enable or disable this feature. You can also set the log file folder path. The path can be anything, so, you can set custom paths as well. The default path here supports the default path of the log files in the case of an Orchard Core and an Orchard 1.x solution too. And here comes the fun part: you can also set to blink or light up continuously a BlinkStick LED stick when a new entry is detected. BlinkStick brings colorful notifications to your computer and wide range programming language implementations give you the power to control LEDs without the need to program a microcontroller and you can choose from different kinds of products. Furthermore, you can also set the color for the LED by providing a hex value or the name of the color. You can find the list of the supported colors here. You just need to plug this device into your USB port and the extension will recognize it! Here you can download this free, open-source extension. In GitHub, you can find the extension's Readme with release notes too. Also, if you encountered bugs or have a feature request please add it on the GitHub page as well. And don't forget to watch the full demo on YouTube! News from the community Training Demo updated: how to add an ASP.NET Core middleware to your Orchard Core application? Orchard Core Training Demo module is a demo Orchard Core module for training purposes guiding you to become an Orchard developer. You can use this module as part of a vanilla Orchard Core source that including the full source code - which is the recommended way. You can use it as part of a solution the uses Orchard Core NuGet packages, however, it's harder to look under the hood of Orchard Core features. The module assumes that you have a good understanding of basic Orchard concepts and that you can get around the Orchard admin area (the official documentation may help you with that). You should also be familiar with how to use Visual Studio and write C#, as well as the concepts of ASP.NET Core MVC. We have just added a new section to our module about how to implement an ASP.NET Core middleware in your Orchard Core application. Take a look at the RequestLoggingMiddleware.cs file! Orchard Dojo Newsletter Now we have 130 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

Culture picker on the Setup page, CodeMirror editor for TextField - This week in Orchard (28/03/2020)

This week you could see a demo about the brand new culture picker on the Setup page! We will also check the new CodeMirror editor for the TextField, the new EmailAddressValidator service, a new Orchard Nuggets blog post and Lombiq's Open-Source Orchard Core Extensions! And that's not all! Orchard Core updates CodeMirror editor for TextField There is a new editor for the TextField, where you can use CodeMirror. To try this just install your site using the Blog recipe and edit the content definition of the BlogPost content type. Set the editor type of the Subtitle TextField to Code Mirror, then hit Save. And now if you edit the predefined blog post or create a new one, you will see the changed editor for the Subtitle TextField. It uses a text area, and of course, supports to write code here by different kinds of highlighting. Add DataAnnotation default error messages There is an issue filed that the DataAnnotation attributes are not localized correctly, because the actual strings to be localized are taken from resources or hard-coded in the DataAnnotation classes. In these cases, we don't have them in the PO files, so they can't be translated because the PO extractor doesn't find them. To solve that there is a new DataAnnotationsDefaultErrorMessages class, that defines all the strings that are currently in the resx files of ASP.NET, but as a custom class with calls to the StringLocalizer. This way the PO file extractor can find them and we can localize them in Crowdin and provide the missing PO files for that. The second step is actually to use them and ensure it works, but also be able to extract custom messages that you would put in the DataAnnotation. In a DataAnnotation like EmailOrRequired you might say Email but provide a custom string. In this case, in the custom string, we still need to extract it. At least the default messages that are nowhere in the code should be registered somewhere like this. So, we can have a reference list of things to translate and then the localizer will be able to pick the correct translation. That's a good first step. Prevent anonymous users from performing GET on content item API You want anonymous users to be able to view your site, view your page/content item and it would just show what the layout is or the view is. But you might not want anonymous users to retrieve the full content item JSON payload, because it might show some properties and metadata that you don't want to expose. Now there is custom permission that is called GetApiContent that you can assign to specific roles and this is not assigned to anonymous users by default. Update Documentation for non-Visual Studio users Getting started with an Orchard Core Theme page of the Orchard Core Documentation has been updated with guides about how to create a new theme if you are using other IDE then Visual Studio. Add EmailAddressValidator service This one is to make a new IEmailAddressValidator service that is available by default in Orchard.Infrastructure.Abstractions. It's using MailKit so that's a new service that you can use to validate email. And if you would like to replace it, you can add your own logic for email validation. Add tenant description Now you can define a description of the views for each tenant. If you add a new tenant by navigating to Configuration -> Tenants -> Add Tenant, see the list of tenants or use the Create Tenant Task in your workflows, you will meet with this new option. Demos Culture picker on the Setup page When you have the latest dev you have this Setup screen where the new thing is the culture picker at the top right. Note that the Change language string not has been localized yet, so the default behavior is that it will show up using whatever language has been selected, the default one comes from the browser. Or if there is no match from your system, the default will be English. That won't configure the site for the same language because it's just the setup experience, so it won't enable localization by default. Because we have a quite much language translated and supported, the UI will adapt automatically to the selected one. If you take a language that would be an RTL language like Arabic, the direction of the text will also change. If you are interested in the full demo, don't hesitate to go to YouTube and view the recording! News from the community Orchard Nuggets: How to localize content items? So you want to create an Orchard Core website that presents its content in multiple languages. There are many parts of this, but what about content items? How do you make them ready for localization? In our newest Orchard Nuggets post, we give you the answers! Check out the other posts for more such bite-sized Orchard tips and let us know if you'd have another question! Lombiq's Open-Source Orchard Core Extensions An Orchard Core CMS Visual Studio solution that contains most of Lombiq's open-source Orchard modules and themes. Only those extensions are included which use the latest released version of Orchard (i.e. ones depending on a nightly build are not yet here). Since the extensions are included as git submodules when cloning this repo set git to initialize submodules Bug reports, feature requests, comments, questions, and code contributions are warmly welcome, please do so via GitHub issues and pull requests. Please adhere to our open-source guidelines while doing so. Orchard Dojo Newsletter Now we have 129 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

How to localize content items? - Orchard Core Nuggets

So you want to create an Orchard Core website that presents its content in multiple languages. There are many parts of this, but what about content items? How do you make them ready for localization? We'll assume that you have your site already set up. We'll use the Page content type found in e.g. the Agency setup recipe as an example. First, make sure that you've set up available site cultures on the Orchard dashboard. This is under Configuration, Settings, Cultures (or the /Admin/Settings/localization URL). Set up LocalizationPart for content types to be localized as mentioned in the docs. Now comes the hard part: You need content items' URLs to be generated with the culture in it, so something like "en-US/demo". This is so you can have two versions of a content item, in different languages but with the same slug ("demo"). So, edit the settings of the Autoroute part from under the content type's editor under the Content menu on the admin, Content Definition, Content Types. For the Page type it's here: /Admin/ContentTypes/Page/ContentParts/AutoroutePart/Edit. There you need to change the default Autoroute pattern to include the culture's ID. This you can do by accessing the culture set in LocalizationPart, so the whole pattern will be something like this: {{ Model.ContentItem.Content.LocalizationPart.Culture }}/{{ Model.ContentItem | display_text | slugify }}. That's pretty much it. Now when you create a new Page you'll be able to tell Orchard which culture it belongs to and the URL will automatically reflect that. This is of course not the complete localization story. You'll also need to display the culture options to the user which you can do with the ContentCulturePicker shape as explained here. Other UI labels coming from code need to be localized too with PO files, as you can read about in the docs too. Have fun with your multi-language sites! We also have a follow-up post on how to add a culture URL segment for non-content pages. Did you like this post? It's part of our Orchard Core Nuggets series where we answer common Orchard questions, be it about user-facing features or developer-level issues. Check out the other posts for more such bite-sized Orchard Core tips and let us know if you have another question!

Contained item routing options for Autoroute Part, Helpful Libraries and Extensions - This week in Orchard (20/03/2020)

This week we would like to show you a demo about the contained item routing options for Autoroute Part among the latest changes of Orchard Core. Then don't forget to check out our updated Orchard Core Training Demo module and the brand new Helpful Libraries and Helpful Extensions from Lombiq! Orchard Core updates Toggle all widgets in Flow Part It could be hard to use Flow Part with multiple widgets because you always have to expand each widget item individually. Sometimes it's quite annoying and it breaks the editing flow. To fix this issue now there is a little toggle all widgets button in the insert widget hover line. Using this button you can show and hide the content of a given widget. And of course, if you click on this button in the case of the Container Widget, the whole content of it will be hidden. A future improvement could be to add the same behavior for the Bag Part and Widgets List too. ViewComponents should be searched in Views and Pages There was a need to put a ViewComponent in the Shared folder of the Pages folder and not just into the Views. This is supported in Razor Pages, so now the ComponentViewLocationExpanderProvider has been updated to also search for the ViewComponents in the Pages/Shared folder. Select All checkbox should react to selected items In many views, we had the same issue and this has been fixed in the Contents, Lucene, Tenants, Users, Workflows and Workflow types pages. Now when you select some items from a list (but not all of them), then the select all checkbox will show you a minus icon, instead of a tick. The tick will be only shown there if every item is selected from the list. Let's see an example for it in the Tenants page about how it worked before and how it is working now. Update taxonomy docs The Taxonomies page of the Orchard Core documentation has been updated with two new additions. First, you could find a new example there about how to use the QueryCategorizedContentItemsAsync Orchard Helper, that provides a way to query content items that are categorized with specific terms. Secondly, you will find some words about Tags. What is the purpose of tags and how to access the TagNames property using Razor and Liquid? Move Header zone to body There was a misunderstanding about what the Header zone is in Orchard Core. The Header zone is for the content and not for the metadata, which could be confusing. If you check the Footer zone, you will find that it's inside the body HTML tag, but the Header zone is rendered inside the head HTML tag. From now the SafeMode theme renders the Header inside the body HTML Tag and the TheAdmin theme does that too and also defines a new zone called HeadMeta that renders the content in the head of the layout. Deployment cards equal heights There was an issue that the deployment step card heights are not equal. If the description of the deployment step is only one row long, it will take less space than a deployment step, which description is more than one length long. Now, this issue has been fixed. Demos Contained item routing options for Autoroute Part Let's say you created a new content item with the Taxonomy content type (or just used the Blog recipe) and attached the Autoroute Part to it. Now let's see the settings for this attached Autoroute Part first. Here you will see three new checkboxes to use: Allow contained item routing: Check to allow users to enable routing of child content items. Manage contained item routes: Check to allow this part to apply routes to child content items. Allow absolute path: Check to allow users to enable absolute paths for child content items Put a tick to these three and head back to your taxonomy content item to check the editor of it. Here you will see a new checkbox with the label of Route contained items. Put a tick here and now view your categories content item. The term content type itself doesn't have an AutoRoute Part on it so we just automatically generate a route for them based on the content item ID and the display text. If we want to make the routing a little bit nicer then you could also add an AutoRoute Part to the term content types as well. Let's add the Autoroute Part to the Category content type and set the container settings of the Autoroute Part that we have just mentioned before. Then if you head back to your taxonomy (Categories in case if you are using the Blog recipe) and edit the definition of the Travel Category, you will find a box that will let you specify that a child content item will be routed to an absolute path. Put a tick here and save the content item. And now if you navigate to your taxonomy again and select the Travel term, you will see that the URL of it will be: https://localhost:44300/travel If you uncheck the absolute option of the Travel category, the URL would contain the URL of your taxonomy, like https://localhost:44300/categories/travel But we are just scratching the surface here. If you are interested in the full demo, don't hesitate to go to YouTube and view the recording! News from the community Updated Orchard Core Training Demo module to RC1 Orchard Core Training Demo module is a demo Orchard Core module for training purposes guiding you to become an Orchard developer. You can use this module as part of a vanilla Orchard Core source that including the full source code - which is the recommended way. You can use it as part of a solution the uses Orchard Core NuGet packages, however, it's harder to look under the hood of Orchard Core features. The module assumes that you have a good understanding of basic Orchard concepts and that you can get around the Orchard admin area (the official documentation may help you with that). You should also be familiar with how to use Visual Studio and write C#, as well as the concepts of ASP.NET Core MVC. Now, this module is fully compatible with the RC1 version of Orchard Core. Yes, we know the RC1 version is quite old now, but we've done it a long time ago but didn't get to finish it. Bug reports, feature requests, and comments are warmly welcome, please do so via GitHub. Feel free to send pull requests too, no matter which source repository you choose for this purpose. Helpful Libraries and Helpful Extensions for Orchard Core from Lombiq The Helpful Libraries for Orchard Core containing various libraries that can be handy when developing for Orchard Core CMS, to be used from your own Orchard modules. Includes: Contents Libraries DateTime Libraries with TimeZone conversion Dependency Injection Libraries Localization Libraries MVC Libraries Resource Management Libraries with Resource Filter feature Utilities The Helpful Extensions for Orchard Core is an Orchard Core module containing some handy extensions (e.g. filters for Projector). Bug reports, feature requests, and comments are warmly welcome, please do so via GitHub. Feel free to send pull requests too, no matter which source repository you choose for this purpose. A new website using Orchard 1.x The project Metis enables EETT adjust its strategy regarding Quality Indices in modern technologies and practical measurements in order to be able to measure more effectively the quality characteristics of telecommunications networks, harmonized as much as possible on best practices of other regulators and domestic providers, be in line with the newest international standards and recommendations, and take advantage of the improvements offered by modern research measurement practices. If you are interested in more websites using Orchard and Orchard Core, don't forget to visit Show Orchard. Show Orchard is a website for showing representative Orchard CMS (and now Orchard Core) websites all around the internet. It was started by Ryan Drew Burnett, but since he doesn't work with Orchard anymore, as announced earlier it is now maintained by our team at Lombiq Technologies. Orchard Dojo Newsletter Now we have 125 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

Publish Later feature, Tags - This week in Orchard (13/03/2020)

The Tags feature is now merged to the dev branch of Orchard Core! In our post, you can also read about the improvements of the Content Picker field, see a demo about the Publish Later module and many more! Orchard Core updates Make content picker default to displaying all content types when none are selected There is no reasonable use-case for a content picker to be configured with no DisplayedContentTypes other than it just hasn't been configured yet. On the other hand, it seems reasonable that some circumstances may necessitate picking a content item of an undeterminable content type at setup. So, by using the content picker you could select which content types you wanted to display in the list when you are searching for a content item. Now there is a new option which is called DisplayAllContentTypes. This way when you add a new content type you won't have to select it again when specifying the content types to display in your content picker. To try this out just simply add a new Content Picker Field to your type and then head to the settings page of the field. Here you can find the Display All Content Types checkbox, that we have just mentioned before. Put a tick in this box and then create a new content item of your content type. We have added a Content Picker Field to a Page content type. Here you could see that the list of the picker is showing menus, landing pages (named Orchard Core) and page content items, so, everything is here that we have defined on our tenant. Tags The tags PR was merged to the dev branch of Orchard Core. The editor of it shows the list of taxonomy terms as tags and stores every DisplayText of every taxonomy term that is tagged inside the field itself under a custom dynamic property which is not available on the field class itself, but there are extension methods called GetTagNames and SetTagNames to retrieve and set the name of the tags. There is a property on the field itself (on the JSON document of the field) that's called TagNames, that gets all the tag names as a string array based on the DisplayText, when a tag was added to the content item. If you change the DisplayText of a term, then every existing content item that was tagged with this term won't have the new DisplayText. That's a caveat for using this property, the GetTagNames on the field. But it would be super useful when you want to just list the names of tags and the TagNames never change, which they should never do. Don't change the name of the tag from one day to the other. If you do, then your responsibility to update the content items or not to use the TagNames property, but resolve all the content items for every tag and use a dynamic DisplayText. Maybe we want the same possibility on even the default TaxonomyField. And have that property on the field itself as a static property, by explaining the limitation of this property. You can see great demos on YouTube about tags using taxonomies and Open Tags. We have already mentioned these demos in the following This week in Orchard posts: Tags using taxonomies Open Tags Fix for SameSite cookie issue By following the recommendation of the ASP.NET team, now we are checking that based on the browser vendor ID what default value we should send for the SameSite cookie. Most of the servers never set the SameSite property of the cookie. It used to be a default value like None by default. But now Google assumes that no value will mean Lax. So, if you want to keep the None value (that was before by default) we have to set it. There is an update on the ASP.NET framework that set's it by default but there is configuration to change the behavior. But this behavior should not change for some browsers that won't be updated. And this is why the only solution is to check what kind of browser is doing the request to know what value we need to set as the default, like Unspecified, None or Lax or whatever. That's an issue and this is done now. Maintain content item ID across BagPart.ContentItems Before this code every time you would change the elements of a BagPart (even updating some properties), it would regenerate some content item JSON payload for each of the BagPart items, which means the content item IDs would be unique, but new. And it would cause issues when you do workflows or when you do routing for containers. Now the content item IDs are immutable even for BagParts. Recipe properties step There is a new deployment step called Recipe File that lets you define customized properties of the recipe file. If you want to customize the recipe file you have this step and then you will be able to set the properties that you can see on the screen. Demos Publish Later module In the admin UI, head to the Configuration -> Features and enable the Publish Later feature. This module adds the ability to schedule content items to be published at a given future date and time. If you would like to use this feature with your content type you have to edit its definition by attaching the Publish Later Part to it. Let's attach the Publish Later Part to the Blog Post content type! Now create a new blog post! At the bottom of the editor, you will see a new input Tag Helper with the datetime-local input type. If you set the date and the time here and hit the Publish Later button, the current version will be saved as a draft and at the given time it will be automatically published by using a background task. We also have a Cancel Publish Later button, so we can cancel the publishing process from here. And in the SummaryAdmin list, you also had a little message that shows you the date and time when the content item will be published. If you are interested in the full demo, don't forget to watch the YouTube video about it! This contribution is sponsored by a company called Weiss Ratings. News from the community How we are dealing with the coronavirus pandemic? In light of WHO characterizing the Coronavirus outbreak as a pandemic we wanted to disclose how we're dealing with the issue: https://lombiq.com/blog/how-we-are-dealing-with-the-coronavirus-pandemic Orchard Dojo Newsletter Now we have 124 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

ContentElement.OfType extension method, using Pulumi with Orchard Core - This week in Orchard (06/03/2020)

Proposal for new extension method ContentElement.OfType, improved documentation of Orchard Core, UI changes and a demo about how to use Pulumi to programmatically create cloud resources and deploy your Orchard Core application! And finally, let's see the breaking news about the next Harvest! Orchard Core updates Make alerts dismissable in TheAdmin theme Now you can click on a little x at the right-top corner of the alert to close it. Note that this improvement is for the TheAdmin theme. Proposal for new extension method ContentElement.OfType You can iterate over all the properties (let's say parts) of a content item and if this part matches the type you want, then it will let you know. This is a little helper to find the part in the content item or a field in a content part if you know the type that you want. And if there are many of them you will get all of them. For this, you can use the OfType extension method in the ContentExtensions.cs file of the OrchardCore.ContentManagement.Abstractions library. Let's say you would like to get all of the attached PricePart of a content item. In this case, you could do something like this: foreach (var pricePart in contentItem.OfType<PricePart>()){ // } Upgrade blob storage library Upgrading blob storage to use the Azure.Storage.Blobs REST API Client v12 because the v11 client has been identified as not thread-safe, and advice from the Azure team is to upgrade to the v12 library. DataProtection continues to use the old library as it has not been upgraded yet but references it transitively, so we don't need to keep a reference to it. Behavior with regard to directories changes with the REST API Client, so to find directories we now need to enumerate the IAsyncEnumerable with a prefix to see if files exist in the hierarchy. Add create a custom admin theme guide Orchard Core documentation has a new guide explaining how you can add and enable a custom admin theme that uses the TheAdmin as a base theme. Rename ContentField display driver files to resemble class names and conform to conventions Notice that the naming of the DisplayDriver files in OrchardCore.ContentFields was inconsistent and in most cases did not reflect the name of the class within. For example, the HtmlFieldDriver is renamed to HtmlFieldDisplayDriver and the TextFieldDriver is renamed to TextFieldDisplayDriver. Rename GetContentItemIdByAliasAsync into GetContentItemIdByHandleAsync There are methods called GetContentItemByAliasAsync and GetContentItemIdByAliasAsync and these expect a string that is an alias. It can be an alias, but it can also be a slug, an ID or whatever you want. It's like get something by a little name. Based on the prefix of the little name we can find the item. Now these methods have a new name called GetContentItemByHandleAsync and GetContentItemIdByHandleAsync. And the previous methods are now marked as obsolete, so, if you are using these methods, next time you will get a warning message when you build the source code. Validate LinkField URL The validator in the LinkField didn't allow you to use anchor links within the URL input. Now it has been fixed and it's accepting a URL with an anchor. Head to the LinkFieldDisplayDriver.cs and check the code of the UpdateAsync method! Add missing Sender SMTP field and add Author expression editor for the EmailTask Based on the specs, we should be able to set the From and the Sender fields. Today we only ask for From and actually copy it to the Sender. We were missing the Sender field for the SMTP message that we want to send. The sender is optional, it is useful when the email author is different than the email submitter. From now you can use this field when sending an email. And if you are using the Email Task when building your workflow, now there is the expression editor for the From and Sender properties on the task. If you haven't provided the value of the author (in the From field), the value of the Sender field will be used. Sort dropdown widgets alphabetically When having to insert widgets in the FlowPart content editor, the list of all widgets is displayed according to creation date which gets quite messy with a lot of widgets. An easy solution, for now, would be to simply sort the name of the widgets alphabetically to give it some easy structure. So, from now when we list the widgets in the Forms and the Widgets List UI, it's alphabetically ordered. BagPart documentation There is new documentation explaining how to use BagPart in Orchard Core. Here you can also find samples about how to do templating both with Razor and Liquid and what are the available alternates that you can use when working with BagPart. Demos Using Pulumi with Orchard Core By using Pulumi you can programmatically create cloud resources in Azure, AWS, Google Cloud or Kubernetes. In this video, you could see that how does it work in the context of an Orchard Core application, but of course, it works for any website that you want to deploy. It supports the notion of infrastructure as code, that allows you to define your infrastructure literally as code. This is very powerful, because that allows you to create for example your Azure App Service or even a Kubernetes cluster programmatically, so you don't have to do it manually. If you are interested in this demo, don't forget to watch the YouTube video about it! News from the community Breaking news about the next Harvest Based on the ongoing events the best would be to cancel Harvest. Right now there are so many unknowns about the evolution and the spread of the virus. Maybe London will be blocked, maybe Washington will be blocked, we don't know. And by asking about 50 people from everywhere around the world to meet in a closed basement for three days could not be the best idea for know in terms of health. So, Harvest will be postponed until things are settling down. This is the safest choice right now and also the most secure in terms of organization. Orchard Dojo Newsletter Now we have 121 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

Taxonomy and contained content items routing, new options for TitlePart and AliasPart - This week in Orchard (28/02/2020)

New options for TitlePart and AliasPart, adding CodeMirror support for HtmlBodyPart and HtmlField, the Pager shape and demo about the taxonomy and contained content items routing are waiting for you in our upcoming post with many other cool features! And about the news from the community: there is a new Orchard Core website, news about the upcoming Harvest and welcome a new team member in Lombiq Technologies! Orchard Core updates Disable feature confirmation messages When we disable a feature we will get a warning that says that the feature that you would like to disable has dependent features that are enabled. Let's disable the Widgets feature. In this case, we will get the following warning message, because Flows and Layers are built on the Widgets module. New options for TitlePart and AliasPart There is a new setting, called AliasPartOptions. Using this new option you can define that the alias can be editable when editing a content item from the admin UI or make it disabled, which means it will be generated automatically using the defined pattern. And when using the TitlePart, you will also find a new option there, called EditableRequired. This means admins can edit the title of the content item and it needs to have a value because it's required. Html mode for CodeMirror on HtmlField and HtmlBodyPart standard editors CodeMirror is a versatile text editor implemented in JavaScript for the browser. It is specialized for editing code and comes with a number of language modes and addons that implement more advanced editing functionality. And now if you set up your site using the Blog recipe and create a new article, the editor of the HtmlBodyPart will come with the CodeMirror support! Furthermore, the Standard editor mode of the HtmlField is also got the CodeMirror support. Moreover, Orchard Core using the latest version of CodeMirror, which is 5.52.0. Pager shape At the bottom of the documentation of OrchardCore.Navigation you will find code examples both for C# and Liquid about how to use the Pager shape in Orchard Core. Add a recipe step to create scope for OpenID Now you can set the connect scope of the OpenID using recipe steps, that you can do in the following way, that could be found in the documentation of OrchardCore.OpenId. There is also a possibility to set the Token Validation Settings with recipe steps. Here you have to provide: Name: unique name of the validation settings. Audience: defines the intended recipient of the token that must be checked. Authority: the address of the remote OpenID Connect server that issued the token. Filter deployment steps There is a new search box on the UI for the deployment steps to filter the list of the available steps. To check out this feature create a new deployment plan under Configuration -> Import/Export -> Deployment Plans then add a new step to it. In this modal window, you will find the textbox with the Filter placeholder text in it. In our case, we typed settings, which means these three steps will be the results of our search. Sitemaps module We wrote about a very cool feature for Orchard Core, which is the Sitemaps support three times now: here, here and here. In every post, we described the features of this module and showed the way how you can use them. And you can also find a recording of this feature on YouTube. The reason why we mentioned that is because this feature is now merged in the dev branch of Orchard Core, thanks to Dean Marcussen! He also added nice documentation about how to create sitemaps, localize sitemaps, cache sitemaps and so on. Setting and Removing HttpContext.Items from Liquid template Now there is a new Liquid filter called httpcontext_add_items, that adds key/value to the HttpContext.Items collection. And you can also remove items from the HttpContext by using the httpcontext_remove_items Liquid filter. You can read more about these two new Liquid filters in the documentation. Do note though that there are possible security implications to this, see the discussion under the pull request. Support most commonly used error pages According to Pingdom research, the top 5 most common errors are 401, 400, 404, 403, 500. So, this is about adding more custom views for error codes that you can change in your themes. Check the content of the DiagnosticsController.cs in the OrchardCore.Diagnostics module. Demos Taxonomy and contained content items routing The main issue is that currently we don't have routing for taxonomies or contained content items. The taxonomy routing is about we would able to route an item inside a taxonomy for a term. The goal is to be able to list all the things that are associated with this term. The issue is that in the case of BagParts or anything that is contained in a content item can't be routed right now, because Autoroute doesn't work on sub-content items. The second thing we looked at was the dynamic routing to be able to define a patterned route in a content item. In this case, multiple URLs would match the same content item and the content item could use these route values to render something differently or do queries. These are two different things, but we are talking about them at the same time. If you are interested in how to do that in Orchard Core check out the following demo on YouTube about this upcoming feature! News from the community A new website using Orchard Core Luxury Card is a global leader in the premium credit card market. From patented metal cards to a 24/7 Concierge service and app, their mission is to shape the industry with innovation, value, and service. With leading airfare and cashback redemption rates along with first-class benefits, they believe your credit card can pay for itself. If you are interested in more websites using Orchard and Orchard Core, don't forget to visit Show Orchard. Show Orchard is a website for showing representative Orchard CMS (and now Orchard Core) websites all around the internet. It was started by Ryan Drew Burnett, but since he doesn't work with Orchard anymore, as announced earlier it is now maintained by our team at Lombiq Technologies. Freshest news about the next Harvest We have a room booked for the dates June 22-24. This is the reserved interval that we will have for sure now. The maximum people can fit in the room is 50 people. The only concern is that it could be not enough, it would be nice to know how many people are interested in coming to the next Harvest. There will be a questionnaire or something to be able to measure somehow the number of people who could be the possible attendees at the next conference. New team member in Lombiq We have a new team member, Gábor! Turned from English studies to competitive gaming to software development and Orchard Core. Check out his bio on our About us page! Orchard Dojo Newsletter Now we have 119 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

Users change email feature, register DisplayDrivers with ContentOptions - This week in Orchard (22/02/2020)

Orchard Core has got very useful and great features again! The blog recipe is extended with predefined search settings and permission with banner images. Now users can change their email address and the documentation of Orchard Core is getting better and better! Then we will see a demo about how to use Orchard Core as a Headless CMS with an Angular 9 client app using GraphQL! Orchard Core updates Add search settings and permissions for the blog recipe Now when creating a new tenant with the Blog recipe it will automatically create all the required assets to make the search page work. This means that you will find a SearchIndex called Search in the recipe and the users in the anonymous role have the permission to query this Lucene search index. Add Media to Blog and Blog post When you install your site using the Blog recipe you will get a sample blog theme with some predefined content that could be very helpful to you if you would like to create a blog using Orchard Core. Now the Blog and the Blog Post content types have a new Media field, called Banner Image. With this new field, you can edit the banner image of the blog and of the blog post. The Blog theme and the recipe is also modified to have a default banner image for both content types. Users Change email feature Head to Configuration -> Features where you will find a new feature called Users Change Email. When you enable this feature (and the Email feature too), this allows users to change their email address. After enabling this feature you will find a new menu under Security -> Settings, called Email. On this page you will find a new checkbox: Allow the users to change their email. If you put a tick here you will get a new endpoint that you can provide for your users. If you navigate to ~/ChangeEmail URL, you will see a screen, where the user can provide the value of the new email address. Document missing global methods If you open the documentation of Orchard Core and head to the Scripting page you will find the list of the global methods that you can use to evaluate scripts. The variables(), parameters() and configurations() methods were missing from this table, now the documentation contains these ones as well. Rendering zones before rendering layout When we used to inject the body in the dynamic layout shape template, it would go over every zone in the layout and render them in memory and only after that called the actual shape layout to be rendered. This way all the zones from footer and header will be invoked after every inner zone. If the inner zone is defining some resources, then they would be taken into account once they are injected in the footer and header. There could be some widgets for instance that would try to define some resources, but they would not be taken into account because the header is already rendered. Check the ExecuteAsync method of the ThemeLayout class in the OrchardCore.DisplayManagement module. Layers documentation Orchard Core documentation has got a new page again! When you navigate to the page of the OrchardCore.Layers module you will find the description of the layers, the list of the predefined layer rules and about how to use zones. Register DisplayDrivers with ContentOptions This change allows you to register custom drivers, but instead in the DI, in a custom data structure. If you crate drivers you have to follow the new way to do that. So, for both Display Modes and Editors, you can customize the Display Driver that will be resolved for the particular mode. This allows you to create custom display drivers that might return a different ViewModel to the standard Display Driver. services.AddContentField<TextField>() .ForDisplayMode<TextFieldDisplayDriver>(d => String.IsNullOrEmpty(d)) .ForDisplayMode<MyCustomTextFieldDisplayDriver>(d => d == "MyCustomDisplayMode"); This example will alter the registration for the TextFieldDisplayDriver to resolve for only the Standard (null) display mode, and register MyCustomTextFieldDisplayDriver to resolve for only the custom display mode. You can find more information about how to register drivers with ContentOptions in the updated documentation of the Content Fields module. Menu: Hide Preview button in admin If you go to edit a menu you saw the Preview button. But you can't preview a menu because a menu is injected in a page like a layout, so there is no specific way to view a menu. If you call Preview on the menu it will try to render the menu without any context and that will not work. Either we add a PreviewPart on the menu and then we can say what page we want to see when we preview the menu that could have been a way to do that. Or the easier solution is to define a placement file where you say that the content preview button shape is hidden when the content type is a menu. This placement file is in the OrchardCore.Menu module. Demos Orchard Core Headless CMS with an Angular 9 client app using GraphQL Watch a great video about how to set up a Headless CMS using Orchard Core then make API calls from an Angular 9 client app using GraphQL! You can find the source code of the demo project in this GitHub repository News from the community New websites using Orchard Core RaiseTheGame is designed to inspire meaningful cultural and behavioral change in all game companies, whatever your size and wherever you are in your diversity and inclusion journey. The guys behind Modern Wolf believes the true test of a publishers value is the decision of those it supports, to work with them again. This mantra is the benchmark against which they base all of their operations and decisions. If you are interested in more websites using Orchard and Orchard Core, don't forget to visit Show Orchard. Show Orchard is a website for showing representative Orchard CMS (and now Orchard Core) websites all around the internet. It was started by Ryan Drew Burnett, but since he doesn't work with Orchard anymore, as announced earlier it is now maintained by our team at Lombiq Technologies. Orchard Dojo Newsletter Now we have 118 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

Display mode options to Parts, Search views for themes - This week in Orchard (14/02/2020)

Display mode options to Content Parts, adding search views for themes, import recipe from a JSON file and many other changes and new features come in our current post. After we will see a real-world example about how to use Orchard Core in production. Then check a new website built with Orchard Core and finally let's talk about the latest news about the Harvest! Orchard Core updates Add revision date in the documentation Now each page of the documentation will display the revision date of the current page. Open any page of the documentation and scroll down to the bottom of it. There you will see the date of the last update. Use ControllerModelUpdater on controller instead of implementing IUpdateModel When you want to Build, Update or Validate your model from controllers, you don't have to implement IUpdateModel, because each of them can be resolved by injecting the IUpdateModelAccessor. Here you can see the NodeController, where we need to build the display for the AdminNode using the TreeThumbnail display type (line 74). Instead of passing this, we can pass the _updateModelAccessor.ModelUpdater. Only show fields in Summary and Detail display types In the past, if you added a field (or a few fields) to a blog it's SummaryAdmin view shows in the list of blog posts. That's because the fields are automatically displayed in SummaryAdmin. Now, this feature prevents to display all the fields automatically in the SummaryAdmin. If you check out a driver of a field, you will see that the values of the Location now changed everywhere in the case of the Initialize method. Add display mode option to parts Now we can have custom display modes for Content Parts too! For example, now you could define which tag would you like for the title and the name of the tag could be the display mode of the TitlePart. Fix themes search views fix Changing all the themes to provide a nice view for the search feature. There was a default version of it, but now each theme has it's own and now it looks great in every built-in theme. If you want to change the look of the search form, you would override the SearchForm template, if you would like to override the search results page, the SearchResults template will be the one you are looking for. But of course, you can override the whole look and feel of the search template just by overriding the Search template. Here you could see the Agency theme with the search form and search results. And you could find really great and detailed documentation about how to implement a website full-text search and everything about the new templates. YesSQL: when to call Session.Save? You can call _session.Save(contentItem) as many times as you want, it's free. It's just marking a content item to be saved once the session will be disposed. There will nothing happen when you call _session.Save(contentItem). If you call it multiple times, the first time it will mark it, the second time it will say: It's already in the dictionary of things to be saved. It will be just a dictionary lookup. Call _session.Save(contentItem) when you think the thing should be saved once the session or the request is done. And if multiple things update a content item and you need to tell the session to save it, they can all call _session.Save(contentItem). Import recipe from a JSON file When you are importing a recipe, you have to upload a ZIP file. The logic then extracted that file and found the JSON file in it. From now you can pass a JSON file when importing a deployment package, not just a ZIP. Recipes documentation And if we are talking about that you can import a recipe from a JSON file, we also need to mention that the documentation of Orchard Core has got a great detailed page about the recipes. Here you could see the format of the recipe, the possible steps of the recipe and see samples about each of the steps (Roles Step, Queries Step, Media Step, Layers Step, etc.). RequireUniqueEmail message Now when you would like to register a new user with an email address, that already exists in the system, you will get an error message says that the email is already used. Demos SaaS and OpenID: a real-world example There is a solution called Trivest Connect (an Enterprise Resource Planning application) that currently includes five different companies. One problem that Trivest solves that everybody sends messages to each other and there is no standardization, that is not so optimal. In the use of Trives Connect with many other features there is a standard document format and with that, it is easier to exchange orders, invoices, VIA, etc. Trivest Connect is based on Orchard Core installed with the Software as a Service recipe that is using the built-in Open ID Server. Here you could see that there are really just a few modules enabled in the admin UI. What customers can do is they can send messages to other customers. This is just an administrator portal because, in reality, this is all done behind the scenes in the ERPs. If you would like to see the whole demo of this real-world example just head to YouTube and watch the recording! News from the community A new website using Orchard Core RA Capital Management is a multi-stage investment manager dedicated to evidence-based investing in public and private healthcare and life science companies developing drugs, medical devices, and diagnostics. And they decided to use Orchard Core to implement their website! If you are interested in more websites using Orchard and Orchard Core, don't forget to visit Show Orchard. Show Orchard is a website for showing representative Orchard CMS (and now Orchard Core) websites all around the internet. It was started by Ryan Drew Burnett, but since he doesn't work with Orchard anymore, as announced earlier it is now maintained by our team at Lombiq Technologies. Latest news about the Harvest There is a new offer from someone from the UK to host Harvest in their offices. They mention 50 people fit in the office. This office is located in London. The possible date for hold the Harvest is the last full week of June. We have to decide the length of the conference and talk about holding a workshop during Harvest. By the past, we have usually done it at the beginning of the week, because this way you can arrive at the weekend, take your time or get back from jetlag or do some tourism. And then if you want you can extend your stay to the week. So 22-23-24 might be the tentative dates. Usually, 2 days are too short and 3 days are too long, but we will see. What do you think about June 22-23? Feel free to comment on that on Gitter too! Orchard Dojo Newsletter Now we have 116 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!

User disabled/enabled events, filter admin menu - This week in Orchard (07/02/2020)

Orchard Core has got several new features and fixes this week! With many others, we will see the new user disabled/enabled events, the new IAreaControllerRouteMapper implementation, the way how you can filter the admin menu then show you a demo about how to integrate stripe.js in your Orchard Core application with workflows. And finally, say some words about a new tentative date and location for the upcoming Harvest! Orchard Core updates Reduce the length of indexes for Content Fields Indexing Let's focus on the LinkFieldIndex and check these two columns: the Url and the BigUrl. The Url is the one that is trimmed and indexed, and the BigUrl is the original data that is not indexed. If you are using MySQL, the maximum length that this provider can support in an index under UTF8 collection is 768. Now we set the maximum length of the indexed columns is to not be longer than the supported length. Do not check "Include all content types" in deployment step by default When you create a content type deployment step, the default is to export all types. Now, this is unchecked by default. Adding User Disabled/Enabled Events The IUserCreatedEventHandler is changed to IUserEventHandler and there are two new events: DisabledAsync and EnabledAsync events. These two new events now triggered in the UserDisplayDriver that will trigger the two newly created workflow events to make it work in your workflows. Adding IAreaControllerRouteMapper Now there is an updated way how the admin prefix is applied by using custom convention and constraint that will ensure that the admin URLs start with the admin prefix. And also ensure that it is done correctly for the controllers that are named AdminController, not the ones that start with admin. Before every controller that starts with admin could be an admin controller, but now with this new convention, it has been decided that only controllers named AdminController can be an admin controller. For example, a controller named AdminItemController doesn't fall into this category, so it can't be an admin controller. A concrete implementation being AdminAreaControllerRouteMapper that uses AdminOptions to provide a default route pattern that is used in the OrchardCore.MVC startup. Just as a reminder, if you have admin controllers you have to name them AdminController or have the Admin attribute on that. This will ensure that the URL is strictly using the admin prefix (or whatever you set it), and the user has the admin permission and this will also apply the admin theme to the views from this controller. Filter admin menu Head to Configuration -> Settings -> Admin and put a tick near the Enable Admin Menu filter checkbox. Now you will have a new textbox at the top of the admin menu with a Filter placeholder text inside it. If you type something here you can filter the menu items and could find easier the option you want. And if you hit CTRL+SHIFT+F, this textbox will get the focus and you can type the menu option that you are looking for without needing to click into this textbox. Add menus content listing and create option If you navigate to the Content option of the admin menu you will find a new one, called Menus. This feature is listing all the menus of the system, and if you can see, there is a new button, called New Menu. By clicking on this button you can create a new Menu without needed the Menu content type to be creatable. Make lists sortable with ordering setting A few weeks ago we write about a way how you can make sortable lists using the Enable Ordering setting of the ListPart and you can also find a demo on YouTube about this feature. The good news is this feature is now merged to the dev branch of Orchard Core! Checkout to the latest changeset of the dev branch and try this feature now. Then don't forget to tell your opinion about it in the comments section! Razor Helpers documentation Now there is a new page in the Orchard Core documentation that contains the extension methods that are available in Razor using @Orchard. This documentation also contains the way how to use an extension method in a view and in a controller too. Demos Stripe.js and Workflows You can use Stripe.js’ APIs to tokenize customer information, collect sensitive card data using customizable Stripe Elements, and accept payments with browser payment APIs like Apple Pay and the Payment Request API. And of course, you can add Stripe.js to your Orchard Core site too! Let's create a registration form where users can register and after successful registration, they can pay the fee for a ticket. After the user submits the form, here comes a huge workflow, that will validate all the fields of the form. Here you can see the several validations, and when there is no error, the workflow will send an email, create an Enrollment in Orchard Core and redirect the user to stripe using a Fork. And there will be another workflow that will validate the payment using the response that Orchard Core will get from stripe.js. Now let's take a closer look at the Create Content Task that creates a new Enrollment content type. When you are creating a new content type using this task, you have to write the properties of the content. This is the JSON that is used to construct the given content item. As you can see, here you can use different Liquid expressions as well, for example, we could use the data coming from the form. You can see the website using this registration form under this URL. Here just click on the Register at the top right and select from the listed options. If you would like to see the whole demo just head to YouTube and watch the recording! News from the community A new tentative date and location for the next Harvest We have another tentative date for the next Harvest: the last week of June. In this date, we could do it in Europe and in a location that is easier to go from the USA too. London and Amsterdam have airports that can be reached easily from several other countries as well. What do you think about the new date and locations? Orchard Dojo Newsletter Now we have 114 subscribers of the Lombiq's Orchard Dojo Newsletter! We have started this newsletter to inform the community around Orchard with the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post published to Orchard Dojo, including This week in Orchard of course. Do you know of other Orchard enthusiasts who you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this week's Orchard meeting!