@paladox opened this Issue on May 14th 2022 Contributor

I saw the follow:

The following error just broke Matomo (v4.9.1):

Call to undefined function Piwik\Plugins\RssWidget\simplexml_load_string()
in /srv/matomo/plugins/RssWidget/RssRenderer.php line 62      

when visiting /index.php?date=yesterday&module=RssWidget&action=rssPiwik&disableLink=0&widget=1&idSite=8590&period=day

Expected Behavior

Going to /index.php?date=yesterday&module=RssWidget&action=rssPiwik&disableLink=0&widget=1&idSite=8590&period=day is not expected to throw an error.

Current Behavior

An error is thrown when going to /index.php?date=yesterday&module=RssWidget&action=rssPiwik&disableLink=0&widget=1&idSite=8590&period=day.

Possible Solution

Maybe it should be like:

                $rss = @\simplexml_load_string($content);
                if ($rss === false) {
                    throw new \Exception("Failed to parse XML.");


Steps to Reproduce (for Bugs)

  1. Go to /index.php?date=yesterday&module=RssWidget&action=rssPiwik&disableLink=0&widget=1&idSite=8590&period=day


Your Environment

  • Matomo Version: 4.9.1
  • PHP Version: 7.4.28
  • Server Operating System: debian 11
  • Additionally installed plugins:
  • Browser: Safari (v15.4 (17613.
  • Operating System: Mac OS 12.3.1
@paladox commented on May 14th 2022 Contributor

nvm, needs the php-xml extension to be installed.

This Issue was closed on May 14th 2022
Powered by GitHub Issue Mirror