HTMLPurifier path not found

Bug #1733423 reported by Bill Iglesias
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
icingaweb2 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

If I add HTML codes (eg <b> </b>) to the output of my plugin, then icingaweb2 fails to load the HTMLPurifier php file. I get the following error:

Warning: Uncaught ErrorException: require_once(HTMLPurifier/HTMLPurifier.php): failed to open stream: No such file or directory in /usr/share/icingaweb2/modules/monitoring/application/views/helpers/PluginOutput.php:95 Stack trace: #0 /usr/share/icingaweb2/modules/monitoring/application/views/helpers/PluginOutput.php(95): Icinga\Application\ApplicationBootstrap->Icinga\Application\{closure}(2, 'require_once(HT...', '/usr/share/icin...', 95, Array) #1 /usr/share/icingaweb2/modules/monitoring/application/views/helpers/PluginOutput.php(95): require_once() #2 /usr/share/icingaweb2/modules/monitoring/application/views/helpers/PluginOutput.php(41): Zend_View_Helper_PluginOutput->getPurifier() #3 /usr/share/php/Zend/View/Abstract.php(349): Zend_View_Helper_PluginOutput->pluginOutput(' Battery Status...') #4 /usr/share/php/Icinga/Web/View.php(223): Zend_View_Abstract->__call('pluginOutput', Array) #5 zend.view:///usr/share/icingaweb2/modules/monitoring/application/views/scripts/show/components/output.phtml(3): Icinga\Web\View- in /usr/share/icingaweb2/modules/monitoring/application/views/helpers/PluginOutput.php on line 95

I was able to fix it by changing lines 95 and 96 in PluginOutput.php as follows:

            require_once 'HTMLPurifier/HTMLPurifier.php';
            require_once 'HTMLPurifier/HTMLPurifier.autoload.php';
changed to
            require_once 'HTMLPurifier.php';
            require_once 'HTMLPurifier.autoload.php';

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: icingaweb2 2.1.0-1ubuntu1.2
ProcVersionSignature: Ubuntu 4.4.0-98.121-generic 4.4.90
Uname: Linux 4.4.0-98-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.10
Architecture: amd64
CurrentDesktop: Unity
Date: Mon Nov 20 16:18:58 2017
InstallationDate: Installed on 2015-09-09 (802 days ago)
InstallationMedia: Ubuntu 14.04.3 LTS "Trusty Tahr" - Beta amd64 (20150805)
PackageArchitecture: all
SourcePackage: icingaweb2
UpgradeStatus: Upgraded to xenial on 2017-06-23 (150 days ago)

Revision history for this message
Bill Iglesias (waob) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in icingaweb2 (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.