All pastes #1087943 Raw Edit

Untitled

public text v1 · immutable
#1087943 ·published 2008-07-31 02:25 UTC
rendered paste body
$errors = array();
if (!file_exists($x_CONFIG['directory']['template']['fs'].'/index.php')) {
    $errors['template'][] = array('name' => 'Template does not exist.',
                    'msg' => 'This may be caused by an improperly set configuration variable, the template not existing, or a permissions problem.');
}
if (!is_writeable($x_CONFIG['directory']['thumbnail']['fs'])) {
    $errors['thumbnail'][] = array('name' => 'Thumbnail directory is not writeable.',
                    'msg' => 'The webserver does not have write-access to the thumbnail directory. Please rectify this, for it prevents thumbnails from being generated.');
}

if (count($errors)) {
    foreach ($errors as $type => $suberrors) {
        foreach ($suberrors as $error) {
            echo '<h3>'.$error['name'].'</h3><p>'.$error['msg'].'</p>';
        }
    }
    die();
}