×
Kunena 5.1.3 Released (19 Aug 2018)

The Kunena team has announce the arrival of Kunena 5.1.3 [K 5.1.3] which is now available for download as a native Joomla extension for J! 3.8.x. This version addresses most of the issues that were discovered in K 5.1 and issues discovered during the development stages of K 5.1. This is a maintenance release.

× Please note: The Kunena project team takes NO responsibility for maintaining nor supporting anything in this category.

Question Category view and sef causes 500 error when the url is a non kunena url

More
4 years 3 months ago #1 by alanski
No forum config needed here :)

The issue: we have some old urls after a site move whci h are beyond our control - google just indexes them.
eg "forum/our-services/itemlist/category/100-newsroom"

This is some old mangled url that is from k2 link.

Kunena sees the sef url and assumes its a forum url and tries to fire $category->getLastTopic(); in views/category/view.html.php line 227

This creates a 500 error as the category is null.

This could hurt your SEO if you have urls coming in like this. We found them in Google Webmaster tools.

Our fix was to edit the function displaycategory

function displayCategory($category) {

//add
if(is_null($category))
$app = JFactory::getApplication();
$url = JRoute::_('index.php?option=com_kunena');
$app->redirect($url, true);
return;
//end add

Not sure if this should really be checked in the router? [// Support URIs like: /forum/12-my_category] line 82

Hopefully this helps someone else

Please Log in or Create an account to join the conversation.

  • Not Allowed: to create new topic.
  • Not Allowed: to reply.
  • Not Allowed: to add attachements.
  • Not Allowed: to edit your message.
Time to create page: 0.087 seconds