Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nicholas Westby 2054 posts 7100 karma points c-trib
    Nov 25, 2013 @ 17:57
    Nicholas Westby
    0

    Impossible to Use Custom Document Types with uBlogsy?

    Based on the (seemingly outdated) documentation, there should be a ublogsy.config file created during intallation. Didn't see one. I did see a number of other config files (ucommentsy.config, and so on).

    Looking at the source code of uBlogsy (https://bitbucket.org/anthonydotnet/ublogsy/src/e8dbdcc696fcda28367b708ad145a100240d9a29/uBlogsy/uBlogsy.BusinessLogic/DataService.cs?at=mvc), it appears that the document types are hardcoded. This is causing some errors for me, such as in the RSS feed (uBlogsyRss.cshtml). I am getting a null reference exception on this line:

    var posts = PostService.Instance.GetPosts(Model.Content, tag, label, author, searchTerm, commenter, year, month, day, out postCount).ToIPublishedContent(true);

    Looks like GetPosts calls DataService.GetLanding, which has a hardcoded (rather than configured) document type (since I am not using that document type, I am getting a null reference):

    var landing = node.AncestorOrSelf("uBlogsyLanding");

    Is it impossible to use custom document types with uBlogsy? Note that I'm on Umbraco 6.1.6 and uBlogsy 3.0.1.

  • Anthony Dang 1404 posts 2558 karma points MVP 3x c-trib
    Dec 16, 2013 @ 14:17
    Anthony Dang
    0

    Hi

    The rss was alwasy inteded to be under the blog node, as it's a feed for the blog.

    The root of the blog has to be a uBlogsyLanding. This was never inteded to be configurable. You can have the blog under your site root.

    eg.

    Content
    - mysite
        - blog 

    The source is here if you need to do something custom:

    https://bitbucket.org/anthonydotnet/ublogsy/branch/mvc

    I was considering making those doctype aliases configurable. It has wider implications for the package though as it complicates things like lucene indexes.

     

     

     

     

  • Nicholas Westby 2054 posts 7100 karma points c-trib
    Jan 04, 2014 @ 06:32
    Nicholas Westby
    0

    Darn, that's what I suspected. In any event, I decided uBlogsy wasn't going to work for me (I have multiple "blogs" on my site, each which needs a different document, e.g. for restricting child node types), and I've already built the site I was working on.

    I was able to use some of uCommentsy though. There were some bugs, but I got it working.

  • Anthony Dang 1404 posts 2558 karma points MVP 3x c-trib
    Jan 04, 2014 @ 19:12
    Anthony Dang
    0

    No worries.

    Glad you got something working.

     

Please Sign in or register to post replies

Write your reply to:

Draft