# Php problem with apache and mythweb [SOLVED]

## ebike

Hi All,

I am trying to get mythweb going again after an upgrade of both apache and php. I am getting the following error when I try to access my mythweb

page:

```

Error at /var/www/localhost/htdocs/mythweb/includes/init.php, line 98:

require_once(includes/db.php) [function.require-once]: failed to open stream: No such file or directory

Fatal error: require_once() [function.require]: Failed opening required 'includes/db.php' (include_path='.:/usr/share/php5:/usr/share/php') in /var/www/localhost/htdocs/mythweb/includes/init.php on line 98

```

It seems to be a php issue, but I am not sure what to do next.

Thanks,

----------

## Hagar

edit /var/www/localhost/htdocs/mythweb/includes/init.php

Change line 98 into "require_once("db.php");"

----------

## ebike

Wasn't any help I'm afraid .. the error is now:

```

Error at /var/www/localhost/htdocs/mythweb/includes/init.php, line 99:

require_once(db.php) [function.require-once]: failed to open stream: No such file or directory

Fatal error: require_once() [function.require]: Failed opening required 'db.php' (include_path='.:/usr/share/php5:/usr/share/php') in /var/www/localhost/htdocs/mythweb/includes/init.php on line 99

```

I had a look in the /usr/share/php5 path, and there is nothing.

----------

## Hagar

well if db.php isn't part of mythweb then you'll have to get it somewhere else.

----------

## ebike

Strange .... it should be a dependancy of mythweb then .. I had a search of portage, and there is no

such animal .. surely someone else has had this problem if that is the case?

----------

## Hagar

Which version are you using?

I've been looking at it but the latest version doesn't even mention a db.php

----------

## ebike

Version is www-apps/mythweb-0.20_p11329, what version are you using?

----------

## Hagar

The same one.

Have you tried to remerge it yet?

----------

## ebike

Ok, I think I have found the issue. I had an older version of apache, I re-emerged a newer version and I don't get that error any more. However I now have a new error:

```

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Apache Server at 192.168.0.3 Port 80

```

My relevant section of the /etc/apache2/http.conf file is this:

```

<Directory /var/www/localhost/htdocs/mythweb>

    Options FollowSymLinks

    AllowOverride All

</Directory>

```

That is the only mod I did in that file. Is there anything else I had to do?I changed "AllowOverride none" to "All" as per

the mythweb howto, and set the directory path.

Many Thanks.

----------

## drvik

I was having similar issues last night and followed the instructions from the gentoo wiki to successfully get mythweb running...

http://gentoo-wiki.com/HOWTO_Setup_MythTV#mythweb

also don't forget to restart the apache server everytime you make a change....

drvik

----------

## ebike

what use flags did you use for php? There is one use flag in the example that doesn't seem to be used now, it is  "dba"

When I have a look at the available useflags there is a "dbase" one, I wonder if this replaces "dba".

I followed the instructions and am back to the original error. I am now trying to compile php with the "dbase" useflag to

see if that does the trick.

And yes, I allways restart apache2 after every change I make.

----------

## drvik

 *Quote:*   

> bigfoot ~ # emerge -pv php
> 
> These are the packages that would be merged, in order:
> 
> Calculating dependencies... done!
> ...

 

this is the package currently working in my system... rechecked it while i was at work today....

drvik

----------

## ebike

Hi,

Apart from unicode, I have the same flags as you. Looks like the problem is elsewhere.

I will try recompiling apache and mythweb to see if that makes any difference.

Cheers,

----------

## ebike

Ok, it is working now. The recompile of apache and mythweb after playing with the php settings did the trick.

I had to modify the  .htaccess with permissions for my database, but once that was done it was all sweet.

Nice to have mythweb access from work again!

----------

## drvik

Don't you just love mythweb!  It's nice to see the look on peoples faces when you show the concept of remotely administering your multimedia centre...

drvik

----------

## GlenCollins

I concur,

I had the same issue, and I think I did the same thing as you ebike (wasn't quite sure from your post exactly what you did, so just confirming for others) and that was changing dba to the dbase USE flag for PHP.

The How To WIKI has been adjusted also.

Thanks for tracking down the issue ebike.

----------

