Forum

Thread tagged as: Problem, Error

perch_categories() with skip-template (again)

Things were working fine after my last message (thank you again!), but it seems that the latest update 2.7.6 has caused another problem in the same function.

Here is the PHP error message we're getting when trying to run perch_categories with 'skip-template' = true:

Notice: Undefined variable: Template in [...]/perch/core/lib/PerchFactory.class.php on line 620 

Fatal error: Call to a member function find_all_tag_ids() on null in [...]/perch/core/lib/PerchFactory.class.php on line 620 

I tested it in previous versions of Perch, and it was working up through 2.7.5; the issue only appears in the latest version. Don't know if it's relevant, but we are using Runway.

Nicole Mirea

Nicole Mirea 2 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Can you show me the code that causes that?

Drew McLellan

Drew McLellan 2638 points
Perch Support

Never mind - I've got it. Thanks!

Thank you!

Drew McLellan

Drew McLellan 2638 points
Perch Support

Should now me fixed in the current version.

I haven't upgraded to 2.7.8 but the code

$categories = perch_categories(array('skip-template' => true));

doesn't work in 2.7.6 but does work in 2.7.4.