Announcement

#1 2021-01-17 04:08:38

eharris
Member
2021-01-16
2

Error Message

Hello/Hi/Greetings,

Whenever I attempt to click on the "Templates" link under the Configuration header I get the following error message. The line 2172 error message just continues to stream, filling the screen and beyond.

Warning: opendir(./template-extension): failed to open dir: No such file or directory in /home/knightsc/public_html/piwigo/admin/include/functions.php on line 2172

Warning: readdir() expects parameter 1 to be resource, boolean given in /home/knightsc/public_html/piwigo/admin/include/functions.php on line 2175

Warning: readdir() expects parameter 1 to be resource, boolean given in /home/knightsc/public_html/piwigo/admin/include/functions.php on line 2175


The "template-extension" directory the first line of the error message refers do does exist, and has 777 permissions. I'm not sure what more I can do or why the error is appearing.

Thank you in advance for your help.

Offline

 

#2 2021-01-17 15:44:22

erAck
Only trying to help
2015-09-06
2029

Re: Error Message

Make sure it's actually a readable directory and the web server effective user can indeed open it.

Place this script in /home/knightsc/dir-test.php

Code:

<?php
$dir = "./template-extension";
if (is_dir($dir))
{
    if ($dh = opendir($dir))
    {
        while (($file = readdir($dh)) !== false)
        {
            echo "Entry: $file\n";
        }
        closedir($dh);
    }
    else
    {
        echo "Can't open directory: $dir\n";
    }
}
else
{
    echo "Not a directory: $dir\n";
}
?>

Then on the command line enter

cd ~/public_html/piwigo
php ~/dir-test.php

If it displays the entries without error test the same in the browser. For this copy the file to /home/knightsc/public_html/piwigo and as browser URI enter yourdomain/piwigo/dir-test.php (if everything is ok you'll see all entries on one line there but ignore that cosmetical detail).

Remove the ~/public_html/piwigo/dir-test.php file after the test.


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

Offline

 

Board footer

Powered by FluxBB

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