(Solved) MythWeb Uncaught Error Class MythBackend not found

Have a MythTV related problem? Ask for help from other MythTV users here.

Moderator: Forum Moderators

Post Reply
gschaefer
Newcomer
Posts: 5
Joined: Thu Apr 17, 2014 6:26 pm
United States of America

(Solved) MythWeb Uncaught Error Class MythBackend not found

Post by gschaefer » Sat Aug 04, 2018 11:08 pm

In preparation for upgrading to MythTV 29 on Ubuntu 18.04.1, I built a new system and installed MythTV 29 and MythWeb on it. After installing MythWeb, following the instructions at https://www.mythtv.org/wiki/Build_from_Source, I receive the following message when trying to connect to it:

Fatal error: Uncaught Error: Class 'MythBackend' not found in /usr/local/share/mythtv/mythweb/includes/utils.php:56 Stack trace: #0 /usr/local/share/mythtv/mythweb/includes/db_update.php(57): setting('recommend_enabl...', NULL, false) #1 /usr/local/share/mythtv/mythweb/includes/init.php(46): require_once('/usr/local/shar...') #2 /usr/local/share/mythtv/mythweb/mythweb.php(20): require_once('/usr/local/shar...') #3 {main} thrown in /usr/local/share/mythtv/mythweb/includes/utils.php on line 56

I have not been able to locate why the install did not work. I've compared the files in question and they look just like the MythWeb PHP files found on MythTV 0.28, so I'm not sure why they work there but not with MythTV 29.

Anyone else have this problem or are more familiar with how the class MythBackend gets defined so that I can resolve this?

Thanks.
Last edited by Steve Goodey on Tue Aug 07, 2018 7:11 am, edited 1 time in total.
Reason: Added (Solved) to title.

User avatar
pgbennett
Developer
Posts: 250
Joined: Mon Apr 27, 2015 5:41 pm
United States of America

Re: MythWeb Uncaught Error Class MythBackend not found

Post by pgbennett » Sun Aug 05, 2018 10:59 pm

It looks in directories /usr/local/share/mythtv/bindings/php/ and /usr/share/mythtv/bindings/php/ for the MythBackend.php file and others that are needed. Those php files are installed by the main MythTV build and install. Check if they are in one of those directories. If not and they are in a different location you can edit file /etc/apache2/sites-available/mythweb.conf, and uncomment the setenv include_path line and specify the actual location where you have installed those php files. This will be added to the search path when looking for them.

gschaefer
Newcomer
Posts: 5
Joined: Thu Apr 17, 2014 6:26 pm
United States of America

Re: MythWeb Uncaught Error Class MythBackend not found

Post by gschaefer » Mon Aug 06, 2018 2:59 am

I checked for those directories (/usr/local/share/mythtv/bindings/php/ and /usr/share/mythtv/bindings/php/) and neither were on my system, so I did a find for MythBackend.php on the entire system and didn't find that file. Was there something else that needed to be installed that I didn't get by installing mythtv using apt and mythweb using get following the instructions posted at https://www.mythtv.org/wiki/Build_from_Source?

User avatar
bill6502
Developer
Posts: 1085
Joined: Fri Feb 07, 2014 5:28 pm
United States of America

Re: MythWeb Uncaught Error Class MythBackend not found

Post by bill6502 » Mon Aug 06, 2018 3:56 am

Hi,

My MythBackend.php source is in: /home/bill/source/mythtv/mythtv/bindings/php/MythBackend.php
and gets installed in /usr/local/share/mythtv/bindings/php/MythBackend.php. Just examples, you're
files are likely elsewhere. When ./configure is run, make sure that the Python bindings will be installed.

User avatar
pgbennett
Developer
Posts: 250
Joined: Mon Apr 27, 2015 5:41 pm
United States of America

Re: MythWeb Uncaught Error Class MythBackend not found

Post by pgbennett » Mon Aug 06, 2018 12:55 pm

It is likely that the packager has them in a different package, I see there is a package in Ubuntu called php-mythtv. You may have to install that. The designers of the packaging split the results into multiple packages, unlike the build from source which builds everything at once.

gschaefer
Newcomer
Posts: 5
Joined: Thu Apr 17, 2014 6:26 pm
United States of America

Re: MythWeb Uncaught Error Class MythBackend not found

Post by gschaefer » Tue Aug 07, 2018 1:27 am

Thank you! I installed php-mythtv with apt and I now have MythBackend.php on my server located in /usr/share/mythtv/bindings/php/. MythWeb now works on the server.

Post Reply