Thread tagged as: Question

Create collection slug

I am using multiple collections for articles rather than categories. Is there a way of creating a collection slug? I have used the slug template tag on the actual articles successfully but want to create a url-friendly slug for the different collections. At the moment I am having to use the collection title which can introduce spaces and capitals into the url. I know I could url encode etc but wondered if a slug could be created it would be cleaner.

If not will have to rebuild using categories I guess.

Hope that makes sense.

Keith Winter

Keith Winter 0 points

  • 4 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Collections use a key in the same way Regions do, so there's no slug. You could maybe use the urlify attribute:

Thanks Drew that may work for me, if not I'll use categories to organise my collections.

Another question, having tried using categories instead -

I have a collection of 'articles' and have set up categories to subset these.

When I go into admin I can see a list of my articles but I can't see which category they are in. Is there a way of filtering by category or at least showing the category alongside the article title etc?


Drew McLellan

Drew McLellan 2638 points
Perch Support

Not yet, but this is something we have planned. You can customise the listing fields, but categories can't yet be added as there could potentially be many multiples per row.

Ok Drew thanks.