Forum

Thread tagged as: Question

Runway display a spesific category

I have a cetegory which i want to display their items in a list, with heading and short description (without images).

How do i display the category items? Thanks

Here is my Diagnostics


Perch Runway: 2.8.32, PHP: 7.0.12, MySQL: mysqlnd 5.0.12-dev - 20150407 - $Id: 241ae00989d1995ffcbbf63d579943635faf9972 $, with PDO Server OS: Linux, cgi-fcgi Installed apps: content (2.8.32), assets (2.8.32), categories (2.8.32), perch_blog (5.0), perch_members (1.5) App runtimes: <?php $apps_list = array( 'content', 'categories', 'perch_members', 'perch_blog', ); PERCH_LOGINPATH: /pwcms PERCH_PATH: /var/www/vhosts/mysite.com/httpdocs/pwcms PERCH_CORE: /var/www/vhosts/mysite.com/httpdocs/pwcms/core PERCH_RESFILEPATH: /var/www/vhosts/mysite.com/httpdocs/pwcms/resources Image manipulation: GD Imagick PHP limits: Max upload 2M, Max POST 8M, Memory: 128M, Total max file upload: 2M F1: 2edba60ed1f613d6dd804feb202456a2 Resource folder writeable: Yes SCRIPT_NAME: /pwcms/core/settings/diagnostics/index.php REQUEST_URI: /pwcms/core/settings/diagnostics/ DOCUMENT_ROOT: /var/www/vhosts/mysite.com/httpdocs HTTP_HOST: mysite.com
Edward Johansen

Edward Johansen 0 points

  • 4 years ago
Rachel Andrew

Rachel Andrew 394 points
Perch Support

The documentation for categories is here: https://docs.grabaperch.com/functions/categories/perch-categories/

You create a template to display the fields you want to display, as with anything else in Perch.

I have the blog app, and i have read the documentation. I just want to display a category with items in a list with link to the blog page

Sample:

Announcement (category, which has blog 3 post under it)

Blog heading one description content here

Blog heading tow description content here

Blog heading three description content here

It would be helpful if you create samples in your documentations. Can you help me with this?

Drew McLellan

Drew McLellan 2638 points
Perch Support

To clarify, are you looking to display posts by category? If so, the example files with the Blog app do that for you.

Something like

perch_blog_custom([
     'category' => 'my-category-slug',
]);