UPDATES EasyBlog 6.0.11 Released! Update to the latest version now!

Helpdesk

Your Time
Our Time
Response Time
24 — 48 hours
We strive to provide the fastest ever response possible. However, we are not super beings.

Allow at least 24 — 48 hours
  Support is online
Our support specialists is available now. We will attend to you as soon as we can.
  Support is online
High
Hi

I have just realized that Payplans (latest 4.x) is breaking the RSS feeds on my sites. I did some debugging and quickly found that it's a well known issue that affected multiple extensions over the years.

The problem happens because Payplans calls JFactory:getDocument() before the onAfterRoute event. In doing so, it forces Joomla to have a HTML document type and so the RSS feeds are broken.

Very importantly, this will not happen on all sites. It happens on ours because our RSS feeds have URLs such as /blog/feed/rss/

On site with standard Joomla SEF, feeds have URLs such as: /blog/feed/rss/?format=feed. When there's a "?format=feed" in the URL, the problem does not occur.

Note that the same will happen with any non-html request (ie pdf, json) as long as "?format=xxx" is not in the URL.

The bug is caused in 2 locations:

Your system plugin extends the class PPPlugins. In its constructor, this class does:

$this->info = PP::info();
$this->theme = PP::themes();


PP:info() cause the loading of class PayPlans which has $this->doc = JFactory::getDocument(); in its constructor (line 98 of administrator/components/com_payplans/includes/dependencies.php)

and

PP::themes() also has $this->doc = JFactory::getDocument(); in its constructor (line 39 of administrator/components/com_payplans/includes/themes/themes.php)

Both these calls (JFactory::getDocument()) are not allowed in Joomla before onAfterRoute as they cause the bug we are seeing.

It is not legal to call JFactory::getDocument() in the constructor of a system plugin before onAfterRoute has been triggered.
The reason is that before onAfterRoute, the SEF URL has not been decoded yet and so Joomla does not know which format is the document. It therefore forces it to html. That's ok in general but causes a bug for non-html document such as rss feeds, json or pdf.

I have not yet had time to look for a fix myself but it's actually urgent. It appears our RSS feeds are broken due to this issue since we updated to Payplans 4.

Best regards
The replies under this section are restricted to logged in users or users with an active subscription with us