Forum

Thread tagged as: Blog

Perch blog categories

I just updated the blog and Perch core to the latest version - unfortunately all blog posts that are filtered by categories onto different pages have now disappeared. They still exist in the database and via the CMS, but when I filter the posts by categories they suggest none are categorised. When I go into the blog posts, the tick boxes to allot them to categories have disappeared.

I copied the categories folder into templates, but don't know what else I was supposed to do because documentation in my line of sight doesn't mention this.

Mallen Baker

Mallen Baker 0 points

  • 7 years ago

Just in case it's relevant, this is how I'm filtering posts:

<?php
                   perch_blog_custom(array(
                         'count' => 5,
                         'sort' => 'postDateTime',
                         'sort-order' => 'DESC',
                            'category' => array('locum-insights'),
                         'template' => 'articles_list.html',
                    ));
     ?>
Drew McLellan

Drew McLellan 2638 points
Perch Support

When you upgraded, did the Blog app run through your posts and create the new categories?

Drew McLellan

Drew McLellan 2638 points
Perch Support

Did you follow the instructions here? https://docs.grabaperch.com/addons/blog/installation/

The answer to the first question is - "don't know".

The answer to the second is "no - I didn't". I didn't know that I needed to, and when searching on the site after the problem occurred, I didn't find that page either.

It would be really helpful if there were upgrade instructions in the actual download in a README file. I looked at the pages on the site it was intuitively obvious to look at - but I didn't find these instructions.

I've pasted the new categories code at the bottom of post.html, and when I edit a post and save it, it now appears where it should do. But does that mean I have to go through 70 posts and do that for each, or is there a way to get this to happen automatically?

Thanks - Mallen

Drew McLellan

Drew McLellan 2638 points
Perch Support

On the page you download from, there's a big bold notice: "If updating from a version prior to 4.5, please read the installation notes." https://grabaperch.com/add-ons/apps/blog

Go to /perch/addons/apps/perch_blog/update and it should run through the posts and apply the categories.

Hi Drew

Thanks for the response.

I really do think you should include upgrade instructions in a README file in the actual download - it means the instructions will always be in a predictable and obvious place, so even idiots like me can see it. I can't see any argument why you wouldn't do this.

Because your 'big bold notice' is not that big and bold, and is two thirds down a block of text under the title 'About the Blog App'. Someone that is updating the app rather than installing it from new will naturally assume they don't need to read that, because they already read it when they first installed, and there's nothing to indicate there's something new and important lurking 'beneath the fold'.

So where did I look?

When I downloaded, I looked in the folder for any notes about upgrade instructions.

I then looked at the documentation page for the Blog App. Since I was upgrading, not installing, it didn't occur to me to look at the link marked 'Installation'. I was looking for 'upgrade instructions'.

Then I tried searching 'upgrade blog app' - that didn't return anything useful. Then I concluded I should just go ahead and upgrade. When it went wrong, I started to do a bunch of searches about blog categories, and didn't get what I needed.

I'm trying to give useful feedback here - important documentation often exists but, to an idiot like me, is not located in the intuitive locations. I'm sure it would reduce the amount of time you have to spend on support if it was.

Rachel Andrew

Rachel Andrew 394 points
Perch Support

We have never distributed important instructions in a README because once the app is packaged we can't then update that README (without shipping a new version of the app).

Quite often we'll realise that an instruction is confusing, or that people are running into a problem due to some webserver configuration. As our instructions are online we can go and add that to the instructions so no-one else hits the issue.

So this is why the instructions are where they are, because by making them a living document we can update them to reflect the issues we see in support.

OK - I get that, but this is still a justification of the status quo that puts that important information on pages I can't find. Could you not assign one consistent place on the website where upgrade instructions are always placed, and then include a README that points to that page? That way you can update instructions whenever you need to, but people can easily find the information they need not to screw their site up on upgrade, which is what I did in spite of having looked for upgrade information.

Drew McLellan

Drew McLellan 2638 points
Perch Support

That place exists - it's the page you download the files from.

I guess I'll just stop trying to be helpful at this point.

I love Perch, and enjoy the podcasts. But my experience of using these forums is being made to feel as though I'm stupid.

I must be in the "idiot" camp too as I've just had the same experience.

A clear separation between "Installation" and "Upgrading" in terms of your Documentation nav would be very helpful especially given the fallout we've both experienced - Why would anyone search for installation instructions when they're actually looking for upgrade instructions? (Not bitching just posing the question ;) )

Good thing I tested on our staging site first...

I have followed the "Updating from a version prior to 4.5" instructions but am still having some issues, I think the main cause being that I have no idea exactly how to "Make sure you have added the Categories app to your apps.php file" as there is no exact example provided like there usually is.

I've tried several combinations like:

include(PERCH_PATH.'/addons/apps/perch_categories/runtime.php');

but looking at my /perch/addons/apps/ folder this path just doesn't physically exist and I can't seem to find a Perch Categories app in your app page so I am at a loss.

Is there something I've missed or overlooked here?

Rachel Andrew

Rachel Andrew 394 points
Perch Support

Hi Gavin

if you are having a problem can you start a new thread with information and also posting your Diagnostic Report. we can't help multiple people in one thread without everyone getting confused.

Thanks!

Ok thanks Rachel will do.

what does that mean: Fatal error: Class 'PerchCategories_Categories' not found in D:\www\www1158\perch\addons\apps\perch_blog\runtime.php on line 491