exit(page_renderer::render_main("Setup complete - Error - $settings->sitename","<p>Oops! Looks like $settings->sitename is already setup and ready to go! Go to the <a href='?action=$settings->defaultaction&page=".rawurlencode($settings->defaultpage)."'>".htmlentities($settings->defaultpage)."</a> to get started!</p>"));
}
// TODO: Check the environment here first
// - Make sure peppermint.json isn't accessible
// - Check for required modules?
// TODO: Add a button to skip the firstrun wizard & do your own manual setup
exit(page_renderer::render_main("Setup complete - Error - $settings->sitename","<p>Oops! Looks like $settings->sitename is already setup and ready to go! Go to the <a href='?action=$settings->defaultaction&page=".rawurlencode($settings->defaultpage)."'>".htmlentities($settings->defaultpage)."</a> to get started!</p>"));
exit(page_renderer::render_main("Missing information - Error - Pepperminty Wiki","<p>Oops! Looks like you forgot to enter a username. Try going back in your browser and filling one in.</p>"));
exit(page_renderer::render_main("Missing information - Error - Pepperminty Wiki","<p>Oops! Looks like you forgot to enter a password. Try going back in your browser and filling one in.</p>"));
}
if(empty($_POST["wiki-name"])){
http_response_code(422);
exit(page_renderer::render_main("Missing information - Error - Pepperminty Wiki","<p>Oops! Looks like you forgot to enter a name for your wiki. Try going back in your browser and filling one in.</p>"));
}
if(empty($_POST["data-dir"])){
http_response_code(422);
exit(page_renderer::render_main("Missing information - Error - Pepperminty Wiki","<p>Oops! Looks like you forgot to enter a directory on the server to store the wiki's data in. Try going back in your browser and filling one in. Relative paths are ok - the default is <code>.</code> (i.e. the current directory).</p>"));