Orchard Core 1.7, customizable user display name and avatar - This week in Orchard (08/09/2023)
We are thrilled to announce that Orchard Core 1.7 is now available! Check out this post to know everything about the latest release of Orchard Core. In the upcoming weeks, we will check out the newest features and additions of Orchard Core 1.7. Let's get started!
Orchard Core updates
Add GraphQL types to the SEO module
The SEO module of Orchard Core provides Search Engine Optimization (SEO) features:
- Meta description, keywords, robots, and custom meta tags
- Canonical URL
- Open Graph metadata
- Twitter Card Tags
- Google schema
If you enable the SEO module, you can attach the SeoMeta Part to your content type that allows SEO meta descriptions to be applied to a content item. Let's enable this module and attach the SeoMeta Part to our sample Blog Post content type! Now, if we edit the predefined blog post, we will have a SEO tab, where we can provide the SEO-related settings.
The issue was all the Seo meta fields should appear in the GraphiQL interface and be queriable. To test out this fix, we have to navigate to Configuration -> GraphiQL and run a query where we want to check out the SEO meta-related fields. Here you can see that we printed the page title, the canonical URL, and the meta description too.
Fix the admin UI sort
When you import many contents with the same ModifiedUtc, the pager logic will not work correctly and some items will be skipped when trying to paginate. With this fix, we add a sort by ID after the sorted value to ensure no records are skipped due to the identical value.
Demos
Customizable user display name and avatar
We wanted a way to be able to change how the user name is displayed because the user name itself is too technical. We really don't have a way to change the displayed user name, so the CrestApps.Components.Users NuGet package contains a feature called User Display Name, that provides a way to change how the user name is displayed. The other feature of this package, User Avatar, provides a way to display an avatar for each user. Let's add this package to our Orchard site and enable both features under the Configuration -> Features screen!
Now if you head to Security -> Users and edit a user, you will find a way to upload an avatar. If you do that and hit Save, you can see your avatar in the top-right corner and in the content items list if you navigate to Content -> Content Items.
The other feature is about changing the whole name. First of all, let's navigate to Configuration -> Settings -> User Display Name! Here you can change how you want the name to be displayed using the Display Name Format select list. Here we specified the First Middle and Lastname format but you can say that you want to use a custom format (if the predefined ones are not suitable for your needs) and use Liquid to define your own format. We also say that you have to specify the first name and the last name for every user (if you edit a user, these values will be required) but the middle name is optional. We will not need the display name text box on the user editor, we will generate it using the display name format.
If we edit an existing user, we will have the First Name, Middle Name, and Last Name text boxes. If we enter some values inside, you will see that the format of the user name has been changed in the top-right corner (and in the content items list if you navigate to Content -> Content Items) based on the format we have just set up earlier.
If you would like to know more about these features along with some technical details and more goodies, head to YouTube for a recording!
News from the community
Orchard Core 1.7
The community recently released the latest 1.7 version of Orchard Core with several new features and additions! There's a new SMS and SMS Notifications module that provides a way to send SMS messages and notifications to users using SMS services. And by utilizing the new two-factor SMS Method feature, you can also transmit a two-factor authentication code to the user via SMS. And yes, this means that starting with version 1.7, Orchard Core is shipped with everything you need to secure your app with two-factor authentication.
The Lucene and Elasticsearch features are capable of searching within PDF files because PDF files are indexed by default. As an enhancement, we added a new feature called Media Indexing which extends the media indexing capability to also encompass searching within files with the following extensions .txt, .md, .docx, and .pptx. And we have a lot more to cover! Here are all the details of the release.
Orchard Core is available as a NuGet package which you can easily add to your ASP.NET Core solution. Here’s how you can get started with Orchard Core.
Orchard Dojo Newsletter
Lombiq's Orchard Dojo Newsletter has 547 subscribers! We have started this newsletter to inform the community around Orchard of the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post is published to Orchard Dojo, including This week in Orchard of course.
Do you know of other Orchard enthusiasts who would like to read our weekly articles? Tell them to subscribe here!