Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7081251
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T06:53:48+00:00 2026-05-28T06:53:48+00:00

I am trying to build a Latest Comments widget for Orchard CMS. I know

  • 0

I am trying to build a “Latest Comments” widget for Orchard CMS.

I know I could directly query the SQL, but is there an API I can use in Orchard to get the latest comments on the whole blog (and which blog post each comment belongs to, etc)? I’ve been looking at IContentManager::Query, but I’m not exactly clear how I can use this to get the information I want.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T06:53:49+00:00Added an answer on May 28, 2026 at 6:53 am

    Check out the CommentsService in the Orchard.Comments module. Orchard.Comments.Services.CommentsService. It’s really close to what you need. Since the service returns the query, you could just tack on some additional sorting like this…

    var query = commentsService.GetCommentsForCommentedContent(blogId);
    var comments = query.OrderByDescending(c => c.CommentDateUtc).Slice(10);
    

    Something like that.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to build a Linq to XML Query but havent found a real
We're developing an EPiServer-based website and trying to deploy our latest build onto a
I pulled the latest source from github. I'm trying to build: stephan@E6520:~/dev/ember.js$ rake rake
I'm trying to build a REST-ful API for my app. Currently I have something
Im trying to make a gallery piece for my website. I know there are
I'm trying to build Hercules from the latest Subversion on Mac OS X 10.6.
Trying to build a somewhat complicated WordPress query. In one query, I'm trying to:
I am trying to build the latest pypy repo on a Mac machine. One
I'm trying to build the latest version of pylibmc (1.2.2) to support SASL on
I am trying to build a mobile app but am having some trouble getting

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.