xref: /webtrees/resources/views/setup/step-3-database-type.phtml (revision b0fcccb03b84c12d54b4ae85014c3af52863d08c)
1<?php
2
3use Fisharebest\Webtrees\I18N;
4
5?>
6
7<form method="post" autocomplete="off">
8    <input name="lang" type="hidden" value="<?= e($lang) ?>">
9    <input name="dbname" type="hidden" value="<?= e($dbname) ?>">
10    <input name="tblpfx" type="hidden" value="<?= e($tblpfx) ?>">
11    <input name="wtname" type="hidden" value="<?= e($wtname) ?>">
12    <input name="wtuser" type="hidden" value="<?= e($wtuser) ?>">
13    <input name="wtpass" type="hidden" value="<?= e($wtpass) ?>">
14    <input name="wtemail" type="hidden" value="<?= e($wtemail) ?>">
15
16    <h2>
17        <?= I18N::translate('Connection to database server') ?>
18    </h2>
19
20    <?php foreach ($errors as $error) : ?>
21        <p class="alert alert-danger"><?= $error ?></p>
22    <?php endforeach ?>
23
24    <?php foreach ($warnings as $warning) : ?>
25        <p class="alert alert-warning"><?= $warning ?></p>
26    <?php endforeach ?>
27
28    <p>
29        <?= I18N::translate('webtrees needs a database to store your genealogy data.') ?>
30    </p>
31
32    <div class="row form-group">
33        <label class="col-form-label col-sm-3" for="dbhost">
34            <?= I18N::translate('Database type') ?>
35        </label>
36        <div class="col-sm-9">
37            <div class="form-check">
38                <input class="form-check-input" type="radio" name="dbtype" id="dbtype-mysql" value="mysql" <?= $dbtype === 'mysql' ? 'checked' : '' ?>>
39                <label class="form-check-label" for="dbtype-mysql">
40                    MySQL
41                </label>
42            </div>
43
44            <div class="form-check">
45                <input class="form-check-input" type="radio" name="dbtype" id="dbtype-sqlite" value="sqlite" <?= $dbtype === 'sqlite' ? 'checked' : '' ?>>
46                <label class="form-check-label" for="dbtype-sqlite">
47                    SQLite
48                </label>
49            </div>
50
51            <div class="form-check">
52                <input class="form-check-input" type="radio" name="dbtype" id="dbtype-pgsql" value="pgsql" <?= $dbtype === 'pgsql' ? 'checked' : '' ?>>
53                <label class="form-check-label" for="dbtype-pgsql">
54                    PostgreSQL
55                </label>
56            </div>
57
58            <div class="form-check">
59                <input class="form-check-input" type="radio" name="dbtype" id="dbtype-sqlsvr" value="sqlsvr" <?= $dbtype === 'sqlsvr' ? 'checked' : '' ?>>
60                <label class="form-check-label" for="dbtype-sqlsvr">
61                    SQL Server
62                </label>
63            </div>
64
65            <p class="small text-muted">
66            </p>
67        </div>
68    </div>
69
70
71    <hr>
72
73    <div class="d-flex justify-content-between">
74        <button class="btn btn-primary" name="step" type="submit" value="4">
75            <?= I18N::translate('next') ?>
76        </button>
77
78        <button class="btn btn-secondary" name="step" type="submit" value="2">
79            <?= I18N::translate('previous') ?>
80        </button>
81    </div>
82</form>
83