Tags version 0.2 released for EPiServer CMS
Posted on September 5, 2011 by Frederik Vig in EPiServerI’ve done a few updates to the Tags module for EPiServer CMS. The major change is that it’s now using the page’s PageGuid instead of PageLink (PageReference). This guaranties that the reference to the page will be correct, even when used with mirroring.
The other updates I’ve done is added a scheduled job that cleans up and check’s that the tagged pages still exist and that they still have their tag. You’ll need to manually set this up in admin mode. Depending on the size of the site I’ll usually set this to 30 minutes. The job goes through all pages that have a tag and validates them.
I’ve also implemented the TagEngine. This is a very first version so expect a few updates here soon. Here’s ITagEngine.cs
using System.Collections.Generic; using EPiServer.Core; using Geta.Tags.Models; namespace Geta.Tags.Interfaces { public interface ITagEngine { PageDataCollection GetPagesByTag(string tagName); PageDataCollection GetPagesByTag(Tag tag); PageDataCollection GetPagesByTag(string tagName, PageReference rootPageReference); PageDataCollection GetPagesByTag(Tag tag, PageReference rootPageReference); IEnumerable<PageReference> GetPageReferencesByTags(string tagNames); IEnumerable<PageReference> GetPageReferencesByTags(IEnumerable<Tag> tags); IEnumerable<PageReference> GetPageReferencesByTags(string tagNames, PageReference rootPageReference); IEnumerable<PageReference> GetPageReferencesByTags(IEnumerable<Tag> tags, PageReference rootPageReference); } } |
You’ll of course find Tags for EPiServer CMS on nuget.episerver.com. Go and give it a try – please let me know how things go and if you have any feedback, leave a comment, tweet me or send me an email.
Michel Radosavljevic says:
Post Author September 12, 2011 at 11:57Hi,
I think this looks really nice! I stumbled on one problem though, when using EPiImage and Tags on the same page type EPiImage gallery breaks. The problem I think, is that both properties use jquery ui. Have you experienced the same problem?
Frederik Vig says:
Post Author September 12, 2011 at 12:46I’ve not used them together yet. You might be right on the jQuery UI part. I’ll check it up. Thanks!
Frederik Vig says:
Post Author September 17, 2011 at 15:27Hi Michel
I can confirm that jQuery UI is the problem. The Tags property will work fine, but EPiImageGallery will break because it uses a legacy version of jQuery UI. Your best bet is to contact the developers behind EPiImage and ask them to upgrade to the latest version of both jQuery and jQuery UI.
Frederik
Michel Radosavljevic says:
Post Author September 29, 2011 at 14:44Hi again,
Found the same as you. We changed EpiImage to use the latest version of jquery and UI and we got it to work. Really like the tagging property! Have a feature request though =) It would be nice if the list you get back from GetPageReferencesByTags would be sorted with the page with most tag matches first, that would be handy when finding related pages for instance.
Joshua Folkerts says:
Post Author September 18, 2012 at 21:06I agree with Michel. We are using Tags right now and would love to see pages that contain the most tags first.
Frederik Vig says:
Post Author September 30, 2012 at 19:57@Michel and Joshua – in version 0.04 I’m now sorting after tag count
Joshua Folkerts says:
Post Author November 20, 2012 at 23:42Thanks Frederik. I like to see projects that are maintained and not left by the wayside. Appreciate the response.
Martin says:
Post Author December 16, 2013 at 12:02Thanks Frederik,
I tried to install Tags on EPiServer 7.5 today and wasnt able to make it work. Are there issues with 7.5?
Frederik Vig says:
Post Author December 16, 2013 at 12:23@Martin I haven’t tried it. Could you create an issue here: https://github.com/Geta/tags/issues and I’ll follow up.
Frederik