Announcement

#1 2023-03-13 20:09:32

hodgman
Member
2022-02-09
7

Uncaught Error: Call to undefined function get_nb_available_tags()

All,

The subject error occurs intermittently.  DreamHost support suggests someone on this forum might have an idea of what could cause this.  The entire message displayed:

Fatal error: Uncaught Error: Call to undefined function get_nb_available_tags() in /home/dick/photos.hodgman.org/html/piwigo/include/menubar.inc.php:298 Stack trace: #0 /home/dick/photos.hodgman.org/html/piwigo/include/menubar.inc.php(15): initialize_menu() #1 /home/dick/photos.hodgman.org/html/piwigo/index.php(103): include('/home/dick/phot...') #2 {main} thrown in /home/dick/photos.hodgman.org/html/piwigo/include/menubar.inc.php on line 298

When the error is displayed, it recurs on refresh and on reload, and sometimes the correct content is later displayed spontaneously.  A later reload can return the correct content, or the error. 

https://photos.hodgman.org/piwigo/

I suspect a server problem, but do not have access to the server logs, only to the logs for my website.  The website error log shows the above text as the first error. 

Thanks for your help.

Offline

 

#2 2023-03-14 00:07:32

erAck
Only trying to help
2015-09-06
2035

Re: Uncaught Error: Call to undefined function get_nb_available_tags()

Apparently include/menubar.inc.php lacks including include/functions_tag.inc.php that defines get_nb_available_tags(). Faulty code seems to be executed only if mbMenu block is to be shown.

Try editing include/menubar.inc.php and after
include_once(PHPWG_ROOT_PATH.'include/block.class.php');
on line 13 add the line

Code:

include_once(PHPWG_ROOT_PATH.'include/functions_tag.inc.php');

Untested. Please report back whether it helps.


Running Piwigo at https://erack.net/gallery/

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact