Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
get articles by tag or category
Hi, I'm able to use JournalArticleLocalServiceUtil.getArticles in my jsp portlet to retrieve CMS contents, but I don't see a way to filter this list by tag or category. Can someone guide me? I'm on 5.2 right now
Even doing a SQL or Hibernate query, I don't see how the tag I assign to a content item is referenced as JournalArticle object has no reference to tag or category, does it?
Even doing a SQL or Hibernate query, I don't see how the tag I assign to a content item is referenced as JournalArticle object has no reference to tag or category, does it?
I discovered how to do this and made an addition to a wiki page about it:
Liferay UI Taglib
basically, you can use a liferay-ui:tags-summary tag in your JSP to list associated tags / categories for a specific journalArticle.
Liferay UI Taglib
basically, you can use a liferay-ui:tags-summary tag in your JSP to list associated tags / categories for a specific journalArticle.
Hi. I looked through the taglib code but the taglib just displays tags or categories associated with the journal article. I think the idea is the another way around. Having created a category, i want to look up all the articles that are associated with the category. (the same way the asset publisher does).
Do you know if this is possible?
Thanks a lot!
Do you know if this is possible?
Thanks a lot!