Skip to Content Skip to Menu

🏖 Mid-Summer sale is here! Get 20% off professional and developer memberships with code SUMMER-2026!

CB Activity and Kunena KPATH_FRAMEWORK Error

  • Oishiku
  • Oishiku
  • ONLINE
  • Posts: 27
  • Thanks: 7
  • Karma: 2
5 days 3 hours ago - 5 days 3 hours ago #344331 by Oishiku
Hello,

I have isolated an error involving CB Activity and Kunena on a Joomla 6 site.

Environment
  • Joomla 6.1.2
  • PHP 8.4.23
  • Community Builder 2.11.0
  • CB Activity 7.1.0
  • Kunena 7.0.7
  • Kunena – Community Builder Integration 7.0.7, enabled
  • Content – Kunena Discuss 6.2.1
One account, called Team Writer, created the opening Kunena discussions connected with an article.  

When another logged-in member views Team Writer’s profile, the profile opens normally. That same member can also open the site-wide CB Activity Stream normally.

However, when Team Writer is logged in, two areas fail:
  1. Team Writer’s own profile when the CB Activity profile tab is published.
  2. The site-wide CB Activity Stream, linked from the site as “What’s New” 
Both produce:
Code:
Undefined constant "Kunena\Forum\Libraries\BBCode\KPATH_FRAMEWORK"
I  performed these isolation tests:
  • Changed Team Writer from Administrator to Registered — error remained.
  • Unpublished the CB Forum profile tab — error remained.
  • Unpublished the CB Activity profile tab — Team Writer could open his own profile.
  • Republished the CB Activity tab — the profile error returned.
  • Disabled Content – Kunena Discuss — the “Discuss this article” links disappeared, but the CB Activity errors remained.
  • Logged in as another member — both Team Writer’s profile and the site-wide Activity Stream worked normally.
This problem does not appear to be limited to the profile layout or the Kunena Discuss content plugin. It appears to occur whenever CB Activity is rendered while Team Writer is the logged-in viewer.

Could CB Activity be loading or parsing one of this user’s Kunena activity entries using the  
Code:
KPATH_FRAMEWORK
constant? Is there a user-specific activity record, permission state or Kunena integration cache that should be inspected?

Please let me know which specific redacted log or stack-trace section would be most useful. I do not want to disable CB Activity because it is central to the community interaction.

Thank you. 
Last edit: 5 days 3 hours ago by Oishiku.

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 50620
  • Thanks: 8673
  • Karma: 1474
2 days 13 hours ago #344338 by krileon
Replied by krileon on topic CB Activity and Kunena KPATH_FRAMEWORK Error
CB Activity should only be trying to load Kunena if you've forum activity enabled and/or present on a stream. Please try enabling debug mode and maximum error reporting then provide the full callstack for the error so we can better see where it's coming from more specifically.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

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

  • Oishiku
  • Oishiku
  • ONLINE
  • Posts: 27
  • Thanks: 7
  • Karma: 2
2 days 3 hours ago - 2 days 3 hours ago #344342 by Oishiku
Replied by Oishiku on topic CB Activity and Kunena KPATH_FRAMEWORK Error
Thanks.

With debug + maximum error reporting on, here's what I've found:

Oddly, when I first accessed the profile page this time, it rendered without error — but only because the offending row was initially hidden.
Team Writer's profile now shows many recent "published article" (CB blog/article) activity rows, which render fine. Those newer rows pushed the older Kunena forum-activity row out of the initial visible window, so the profile loaded without error. But as soon as I click "More" (which paginates in the older activity), the Kunena forum row loads and the page immediately fatals with the same error. So the profile isn't actually fixed — the fatal is just deferred until that specific Kunena row is rendered.

The site-wide activity stream still fatals on load, since it renders the Kunena row directly.So the same underlying error is reached from two entry points. Both callstacks converge on the identical Kunena line (
Code:
KunenaBBCode.php:50
), but the middle frames differ:
  • Profile-tab path: via
    Code:
    ActivityTab->getDisplayTab()
  • Stream/component path (below): via
    Code:
    CBplug_cbactivity->getCBpluginComponent()
    /
    Code:
    cbTabs->tabClassPluginTabs()

Full callstack (from the stream, which is the same one produced by clicking "More" on the profile):
Code:
Undefined constant "Kunena\Forum\Libraries\BBCode\KPATH_FRAMEWORK" libraries/kunena/src/BBCode/KunenaBBCode.php:50 Call Stack # Function Location 1 () JROOT/libraries/kunena/src/BBCode/KunenaBBCode.php:50 2 include() JROOT/libraries/vendor/composer/ClassLoader.php:576 3 {closure:Composer\Autoload\ClassLoader::initializeIncludeClosure():575}() JROOT/libraries/vendor/composer/ClassLoader.php:427 4 Composer\Autoload\ClassLoader->loadClass() JROOT/libraries/src/Autoload/ClassLoader.php:59 5 Joomla\CMS\Autoload\ClassLoader->loadClass() JROOT/libraries/kunena/src/Html/KunenaParser.php:280 6 Kunena\Forum\Libraries\Html\KunenaParser::stripBBCode() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/templates/default/activity/core/kunena.php:69 7 require() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/templates/default/activity/core/display.php:69 8 require() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/library/Helper/ActivityHelper.php:601 9 CB\Plugin\Activity\Helper\ActivityHelper::layoutData() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/templates/default/activity/container.php:80 10 require() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/templates/default/activity/rows.php:35 11 require() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/library/Controller/ActivityController.php:2640 12 CB\Plugin\Activity\Controller\ActivityController->show() JROOT/components/com_comprofiler/plugin/user/plug_cbactivity/component.cbactivity.php:396 13 CBplug_cbactivity->getCBpluginComponent() JROOT/libraries/CBLib/CB/Legacy/cbPluginHandler.php:879 14 cbPluginHandler->call() JROOT/libraries/CBLib/CB/Legacy/cbTabs.php:1611 15 cbTabs->_callTabPlugin() JROOT/libraries/CBLib/CB/Legacy/cbTabs.php:1725 16 cbTabs->tabClassPluginTabs() JROOT/components/com_comprofiler/comprofiler.php:732 17 tabClass() JROOT/components/com_comprofiler/comprofiler.php:284 18 require_once() JROOT/libraries/src/Dispatcher/LegacyComponentDispatcher.php:71 19 Joomla\CMS\Dispatcher\LegacyComponentDispatcher::{closure:...dispatch():70}() JROOT/libraries/src/Dispatcher/LegacyComponentDispatcher.php:73 20 Joomla\CMS\Dispatcher\LegacyComponentDispatcher->dispatch() JROOT/libraries/src/Component/ComponentHelper.php:361 21 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/SiteApplication.php:218 22 Joomla\CMS\Application\SiteApplication->dispatch() JROOT/libraries/src/Application/SiteApplication.php:272 23 Joomla\CMS\Application\SiteApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:320 24 Joomla\CMS\Application\CMSApplication->execute() JROOT/includes/app.php:58 25 require_once() JROOT/index.php:51
 It seems the error originates inside Kunena's BBCode class, reached from CB Activity's Kunena activity template whenever a forum-activity row is rendered. CB-native rows (published articles/blogs) render fine — only the Kunena forum row triggers it.
 
Last edit: 2 days 3 hours ago by Oishiku.

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 50620
  • Thanks: 8673
  • Karma: 1474
1 day 11 hours ago #344348 by krileon
Replied by krileon on topic CB Activity and Kunena KPATH_FRAMEWORK Error
Ok, was able to confirm that Kunena activity with Kunena 7.x isn't working properly. Am investigating a fix. Looks like Kunena changed how it's loaded/interacted with (again.. I've got 4 different ways to load Kunena now for backwards compatibility..).


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

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

  • Oishiku
  • Oishiku
  • ONLINE
  • Posts: 27
  • Thanks: 7
  • Karma: 2
1 day 3 hours ago #344351 by Oishiku
Replied by Oishiku on topic CB Activity and Kunena KPATH_FRAMEWORK Error
Hi,

Thanks for looking into this and for confirming the breakdown.   I appreciate the update and would be happy to test a fix when one is available.

 

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 50620
  • Thanks: 8673
  • Karma: 1474
11 hours 12 minutes ago #344356 by krileon
Replied by krileon on topic CB Activity and Kunena KPATH_FRAMEWORK Error
Ok, compatibility for Kunena 7 and hopefully future releases has been implemented into the following via nightly builds.

CB Activity
CB Gallery
CB AntiSpam
CB Auto Actions
CB GroupJive

I'm still working on a core CB release, but it seams to be working fine still regardless will update it to newer API loading behavior. All of the above have discontinued support for Kunena 5 (released 10 years ago.. time to let that one go!). Only 6 and 7 are supported now.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: Oishiku

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

Moderators: beatnantkrileon
Powered by Kunena Forum