<div class="install-container">
    <h3 class="screen-reader-text">Set up your database connection</h3>
    <form method="post" action="<?= base_path() ?>index.php/settup">
        <div class="form-group row">
            <label for="driver" class="col-sm-4 col-form-label">Driver <span class="required">*</span></label>
            <div class="col-sm-8">
                <select id="driver" name="driver" class="form-control">
                    <option value="sqlsrv">sqlsrv</option>
                    <option value="odbc">odbc</option>
                    <option selected value="dblib">dblib (linux)</option>
                </select>
            </div>
        </div>
        <div class="form-group row">
            <label for="host" class="col-sm-4 col-form-label">Host <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="host" id="host" type="text" size="25" value="localhost" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="port" class="col-sm-4 col-form-label">Port</label>
            <div class="col-sm-8">
                <input name="port" id="port" type="text" size="25" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="username" class="col-sm-4 col-form-label">Username <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="username" id="username" type="text" value="sa" size="25" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="password" class="col-sm-4 col-form-label">Password <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="password" id="password" type="text" size="25" autocomplete="off" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="dbname" class="col-sm-4 col-form-label">Database Name <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="dbname" id="dbname" value="MuOnline" type="text" size="25" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="dbname" class="col-sm-4 col-form-label">Database Account</label>
            <div class="col-sm-8">
                <input name="me" id="me" value="MuOnline" type="text" size="25" class="form-control" />
            </div>
        </div>
        <div class="form-group row">

            <div class="col-sm-8 offset-sm-4">
                <label for="md5" class="form-check-label">
                    <input name="md5" id="md5" type="checkbox" value="1" class="form-check-input" />
                    MD5
                </label>

            </div>
        </div>
        <div class="form-group row">
            <div class="col-sm-8 offset-sm-4">
                <label for="user-vi-curr-info" class="form-check-label">
                    <input name="user_vi_curr_info" id="user-vi-curr-info" type="checkbox" value="1" class="form-check-input" />
                    Use VI_CURR_INFO
                </label>
            </div>
        </div>

        <h3 class="screen-reader-text">Set up your database columns</h3>

        <div class="form-group row">
            <label for="credit" class="col-sm-4 col-form-label">MEMB_INFO Credits <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="credit" id="credit" type="text" value="credits" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="country" class="col-sm-4 col-form-label">MEMB_INFO country</label>
            <div class="col-sm-8">
                <input name="country" id="country" type="text" value="country" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="avatar" class="col-sm-4 col-form-label">Character avatar <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="avatar" id="avatar" type="text" value="Avatar" class="form-control" required />
            </div>
        </div>
        <div class="form-group row">
            <label for="resets" class="col-sm-4 col-form-label">Character resets</label>
            <div class="col-sm-8">
                <input name="resets" id="resets" type="text" value="Resets" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="master-resets" class="col-sm-4 col-form-label">Character master resets</label>
            <div class="col-sm-8">
                <input name="master_resets" id="master-resets" type="text" value="" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="pk" class="col-sm-4 col-form-label">Character PK</label>
            <div class="col-sm-8">
                <input name="pk" id="pk" type="text" value="PkCountWeb" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="hero" class="col-sm-4 col-form-label">Character Hero</label>
            <div class="col-sm-8">
                <input name="hero" id="hero" type="text" value="HeroCountWeb" class="form-control" />
            </div>
        </div>

        <h3 class="screen-reader-text">Set up your application</h3>

        <div class="form-group row">
            <label for="timezone" class="col-sm-4 col-form-label">Timezone</label>
            <div class="col-sm-8">
                <select name="timezone" id="timezone" class="form-control">
                    <?php foreach ($timezones as $timezone): ?>
                        <option<?= $timezone === 'America/Sao_Paulo' ? ' selected' : '' ?> value="<?= $timezone ?>"><?= $timezone ?></option>
                    <?php endforeach ?>
                </select>
            </div>
        </div>
        <div class="form-group row">
            <label for="base-path" class="col-sm-4 col-form-label">Base path</label>
            <div class="col-sm-8">
                <input name="base_path" id="base-path" type="text" value="" class="form-control" />
            </div>
        </div>

        <h3 class="screen-reader-text">Set up your Admin Credentials</h3>
        <div class="form-group row">
            <label for="admin-username" class="col-sm-4 col-form-label">Username <span class="required">*</span></label>
            <div class="col-sm-8">
                <input name="admin_username" id="admin-username" type="text" value="" class="form-control" />
            </div>
        </div>
        <div class="form-group row">
            <label for="admin-password" class="col-sm-4 col-form-label">Password <span class="required">*</label>
            <div class="col-sm-8">
                <input name="admin_password" id="admin-password" type="text" value="" class="form-control" />
            </div>
        </div>

        <input name="submit" type="submit" value="Install" class="btn btn-block btn-primary" />
    </form>
</div>