1<?php use Fisharebest\Webtrees\I18N; ?> 2 3<form method="POST" autocomplete="off"> 4 <input name="route" type="hidden" value="setup"> 5 <input name="lang" type="hidden" value="<?= e($lang) ?>"> 6 <input name="dbtype" type="hidden" value="<?= e($dbtype) ?>"> 7 <input name="wtname" type="hidden" value="<?= e($wtname) ?>"> 8 <input name="wtuser" type="hidden" value="<?= e($wtuser) ?>"> 9 <input name="wtpass" type="hidden" value="<?= e($wtpass) ?>"> 10 <input name="wtemail" type="hidden" value="<?= e($wtemail) ?>"> 11 12 <h2> 13 <?= I18N::translate('Database connection') ?> – PostgreSQL 14 </h2> 15 16 <?php foreach ($errors as $error) : ?> 17 <p class="alert alert-danger"><?= $error ?></p> 18 <?php endforeach ?> 19 20 <?php foreach ($warnings as $warning) : ?> 21 <p class="alert alert-warning"><?= $warning ?></p> 22 <?php endforeach ?> 23 24 <div class="row form-group"> 25 <label class="col-form-label col-sm-3" for="dbhost"> 26 <?= I18N::translate('Server name') ?> 27 </label> 28 <div class="col-sm-9"> 29 <input class="form-control" id="dbhost" name="dbhost" type="text" value="<?= e($dbhost) ?>" dir="ltr"> 30 <p class="small text-muted"> 31 <?= I18N::translate('Most sites are configured to use localhost. This means that your database runs on the same computer as your web server.') ?> 32 </p> 33 </div> 34 </div> 35 36 <div class="row form-group"> 37 <label class="col-form-label col-sm-3" for="dbport"> 38 <?= I18N::translate('Port number') ?> 39 </label> 40 <div class="col-sm-9"> 41 <input class="form-control" id="dbport" name="dbport" pattern="\d+" type="text" value="<?= e($dbport) ?>" dir="ltr"> 42 <p class="small text-muted"> 43 <?= I18N::translate('Most sites are configured to use the default value of 5432.') ?> 44 </p> 45 </div> 46 </div> 47 48 <div class="row form-group"> 49 <label class="col-form-label col-sm-3" for="dbuser"> 50 <?= I18N::translate('Database user account') ?> 51 </label> 52 <div class="col-sm-9"> 53 <input class="form-control" id="dbuser" name="dbuser" type="text" value="<?= e($dbuser) ?>" dir="ltr"> 54 <p class="small text-muted"> 55 <?= I18N::translate('This is case sensitive.') ?> 56 </p> 57 </div> 58 </div> 59 60 <div class="row form-group"> 61 <label class="col-form-label col-sm-3" for="dbpass"> 62 <?= I18N::translate('Database password') ?> 63 </label> 64 <div class="col-sm-9"> 65 <input class="form-control" id="dbpass" name="dbpass" type="password" value="<?= e($dbpass) ?>" dir="ltr" autocomplete="off"> 66 <p class="small text-muted"> 67 <?= I18N::translate('This is case sensitive.') ?> 68 </p> 69 </div> 70 </div> 71 72 <div class="row form-group"> 73 <label class="col-form-label col-sm-3" for="dbname"> 74 <?= I18N::translate('Database name') ?> 75 </label> 76 <div class="col-sm-9"> 77 <input class="form-control" dir="ltr" id="dbname" name="dbname" pattern="^[^`]+$" type="text" value="<?= e($dbname) ?>"> 78 79 <p class="small text-muted"> 80 <?= I18N::translate('Use letters A-Z, a-z, digits 0-9, or underscores') ?> 81 </p> 82 </div> 83 </div> 84 85 <div class="row form-group"> 86 <label class="col-form-label col-sm-3" for="tblpfx"> 87 <?= I18N::translate('Table prefix') ?> 88 </label> 89 <div class="col-sm-9"> 90 <input class="form-control" dir="ltr" id="tblpfx" name="tblpfx" pattern="^[^`]*$" type="text" value="<?= e($tblpfx) ?>"> 91 <p class="small text-muted"> 92 <?= I18N::translate('The prefix is optional, but recommended. By giving the table names a unique prefix you can let several different applications share the same database.') ?> 93 <?= I18N::translate('Use letters A-Z, a-z, digits 0-9, or underscores') ?> 94 </p> 95 </div> 96 </div> 97 98 <hr> 99 100 <div class="d-flex justify-content-between"> 101 <button class="btn btn-primary" name="step" type="submit" value="5"> 102 <?= I18N::translate('next') ?> 103 </button> 104 105 <button class="btn btn-secondary" name="step" type="submit" value="3"> 106 <?= I18N::translate('previous') ?> 107 </button> 108 </div> 109</form> 110