' . $str . '' . $msg . ''; } // If the config file exists and the auth variables are set, moonmoon is already installed include __DIR__ . '/admin/inc/pwd.inc.php'; if (file_exists(__DIR__ . '/custom/config.yml') && isset($login) && isset($password)) { $status = 'installed'; } elseif (isset($_REQUEST['url'])) { // Do no try to use the file of an invalid locale if (strstr($_REQUEST['locale'], '..') !== false || !file_exists(__DIR__ . "/app/l10n/${_REQUEST['locale']}.lang")) { $_REQUEST['locale'] = 'en'; } $save = array(); //Save config file $config = array( 'url' => $_REQUEST['url'], 'name' => filter_var($_REQUEST['title'], FILTER_SANITIZE_SPECIAL_CHARS), 'locale' => $_REQUEST['locale'], 'items' => 10, 'shuffle' => 0, 'refresh' => 240, 'cache' => 10, 'nohtml' => 0, 'postmaxlength' => 0, 'cachedir' => './cache', 'debug' => false ); $CreatePlanetConfig = new PlanetConfig($config); $save['config'] = file_put_contents(__DIR__.'/custom/config.yml', $CreatePlanetConfig->toYaml()); //Save password $save['password'] = file_put_contents(__DIR__.'/admin/inc/pwd.inc.php', ''); if (0 != ($save['config'] + $save['password'])) { $status = 'installed'; } } else { // We start by malking sure we have PHP5 as a base requirement if(version_compare(PHP_VERSION, '5.4.0') >= 0) { $strInstall = installStatus('Server is running at least PHP 5.4', 'OK',true); $strRecommendation = ''; } else { $strInstall = installStatus('Server is running at least PHP 5.4', 'FAIL',false); $strRecommendation = '
  • Check your server documentation to activate at least PHP 5.4
  • '; } // Writable file requirements $tests = array( '/custom', '/custom/people.opml', '/admin/inc/pwd.inc.php', '/cache', ); // We now test that all required files and directories are writable. foreach ($tests as $v) { if(touch(__DIR__ . $v)) { $strInstall .= installStatus("$v is writable", 'OK', true); } else { $strInstall .= installStatus("$v is writable", 'FAIL',false); $strRecommendation .= "
  • Make $v writable with CHMOD
  • "; } } // We can now decide if we install moonmoon or not $status = ($strRecommendation != '') ? 'error' : 'install'; } ?> <?=_g('moonmoon installation')?>

    Sorry, your server is not compatible with moonmoon.

    Your server does not fulfill the requirements

    Test Result

    Troubleshooting

    To install moonmoon, try the following changes:

    1. Delete install.php with your FTP software.')?>
    2. administration panel')?>