Not signed in (Sign In)

Vanilla 1.1.10 is a product of Lussumo. More Information: Documentation, Community Support.

  1.  
    Warning: opendir(/home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-content/thumbs/ornaments/flower/) [function.opendir]: failed to open dir: No such file or directory in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 96

    Warning: readdir(): supplied argument is not a valid Directory resource in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 98

    Warning: closedir(): supplied argument is not a valid Directory resource in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 102
    the above error occur when I try to move album of one collection to another and the album get moved to the desired collection properly.why is it so??
  2.  
    Notice: Undefined variable: parent_path in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 111

    Notice: Undefined variable: parent_path in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 111

    Notice: Undefined variable: parent_path in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 111

    Notice: Undefined variable: parent_path in /home/vhosts/sariga.freetzi.com/mygallery/ploggerb3/plog-admin/plog-admin-functions.php on line 111
    I also get above mentioned things when I deleted a collection the collection got deleted properly too.Is there any problem in my code that these errors are coming .Actually all the processes of moving and deleting are working properly .What to do to avoid this message from displaying ???If these messages are due to an error in coding then please help me.
    Thanks
    •  
      CommentAuthorsidtheduck
    • CommentTimeOct 8th 2009
     
    sariga,

    These errors do not mean much, just that it failed to delete the automatically generated thumbnails for that album or collection during the move (most likely because they were not created yet). To fix this, you can edit your plog-admin-functions.php file for the kill_dir and kill_file functions as shown below:
    function kill_dir($path) {
    // Great removal function originally named advancedRmdir() by kisgabo94 at freemail dot hu
    // if the path exists, attempt to delete it, else we don't need to do anything
    if (isset($path) && file_exists($path)) {
    $origipath = $path;
    $handler = opendir($path);
    while (true) {
    $item = readdir($handler);
    if ($item == '.' or $item == '..') {
    continue;
    } elseif (gettype($item) == 'boolean') {
    closedir($handler);
    // If safe_mode enabled, open the permissions first
    if (is_safe_mode() && !is_writable(dirname($path).'/')) {
    $parent_path = dirname($path).'/';
    chmod_ftp($parent_path, 0777);
    }
    $remove = @rmdir($path);
    // If safe_mode enabled, close the permissions back down to the default
    if (is_safe_mode()) {
    chmod_ftp($parent_path);
    }
    if (!$remove) {
    return false;
    }
    if ($path == $origipath) {
    break;
    }
    $path = substr($path, 0, strrpos($path, '/'));
    $handler = opendir($path);
    } elseif (is_dir($path.'/'.$item)) {
    closedir($handler);
    $path = $path.'/'.$item;
    $handler = opendir($path);
    } else {
    // If safe_mode enabled, open the permissions first
    if (is_safe_mode() && !is_writable($path)) {
    chmod_ftp($path.'/', 0777);
    }
    @unlink($path.'/'.$item);
    }
    }
    }
    return true;
    }

    function kill_file($file) {
    // if the path exists, attempt to delete it, else we don't need to do anything
    if (isset($file) && file_exists($file)) {
    // Check if it's an uploaded file
    $uploaded = is_uploaded_file($file);
    // If safe_mode enabled, open the permissions first
    if (is_safe_mode() && !$uploaded) {
    $parent_path = dirname($file).'/';
    chmod_ftp($parent_path, 0777);
    }
    $remove = @unlink($file);
    // If safe_mode enabled, close the permissions back down to the default
    if (is_safe_mode() && !$uploaded) {
    chmod_ftp($parent_path);
    }
    if (!$remove) {
    return false;
    }
    }
    return true;
    }
    Thankful People: sarigamanakodam
  3.  
    Thanks very much.The error messages just vanished with these code.