Redesign install

This commit is contained in:
Jay Trees 2022-01-14 14:10:09 +01:00
parent c323e578e5
commit 0b7b775c4b

View file

@ -22,38 +22,41 @@ switch ($step) {
case 1: case 1:
?> ?>
<main> <main>
<section> <div class="ui hidden divider"></div>
<h1>Install</h1> <div class="ui container">
<h2>Step <?= $step ?></h2> <div class="ui segment">
<p>Welcome to the wishthis installer.</p> <h1 class="ui header">Install</h1>
<p>wishthis needs a database to function properly. Please enter your credentials.</p> <h2 class="ui header">Step <?= $step ?></h2>
<p>Welcome to the wishthis installer.</p>
<p>wishthis needs a database to function properly. Please enter your credentials.</p>
<form action="?page=install" method="post"> <form class="ui form" action="/?page=install" method="post">
<input type="hidden" name="step" value="<?= $step + 1; ?>" /> <input type="hidden" name="step" value="<?= $step + 1; ?>" />
<fieldset> <div class="field">
<label>Host</label> <label>Host</label>
<input type="text" name="DATABASE_HOST" placeholder="localhost" value="localhost" /> <input type="text" name="DATABASE_HOST" placeholder="localhost" value="localhost" />
</fieldset> </div>
<fieldset> <div class="field">
<label>Name</label> <label>Name</label>
<input type="text" name="DATABASE_NAME" placeholder="wishthis" value="wishthis" /> <input type="text" name="DATABASE_NAME" placeholder="wishthis" value="wishthis" />
</fieldset> </div>
<fieldset> <div class="field">
<label>Username</label> <label>Username</label>
<input type="text" name="DATABASE_USER" placeholder="root" value="root" /> <input type="text" name="DATABASE_USER" placeholder="root" value="root" />
</fieldset> </div>
<fieldset> <div class="field">
<label>Password</label> <label>Password</label>
<input type="text" name="DATABASE_PASSWORD" /> <input type="text" name="DATABASE_PASSWORD" />
</fieldset> </div>
<input type="submit" value="Continue" /> <input class="ui primary button" type="submit" value="Continue" />
</form> </form>
</section> </div>
</div>
</main> </main>
<?php <?php
break; break;
@ -73,17 +76,20 @@ switch ($step) {
file_put_contents($configPath, $configContents); file_put_contents($configPath, $configContents);
?> ?>
<main> <main>
<section> <div class="ui hidden divider"></div>
<h1>Install</h1> <div class="ui container">
<h2>Step <?= $step ?></h2> <div class="ui segment">
<p>Click Continue to test the database connection.</p> <h1 class="ui header">Install</h1>
<h2 class="ui header">Step <?= $step ?></h2>
<p>Click Continue to test the database connection.</p>
<form action="?page=install" method="post"> <form class="ui form" action="?page=install" method="post">
<input type="hidden" name="step" value="<?= $step + 1; ?>" /> <input type="hidden" name="step" value="<?= $step + 1; ?>" />
<input type="submit" value="Continue" /> <input class="ui primary button" type="submit" value="Continue" />
</form> </form>
</section> </div>
</div>
</main> </main>
<?php <?php
break; break;