xref: /webtrees/resources/views/admin/analytics-edit.phtml (revision 22c135fa2a9d8aaf68a70032269940d5314a9818)
1<?php
2
3use Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
4use Fisharebest\Webtrees\Http\RequestHandlers\ModulesAllPage;
5use Fisharebest\Webtrees\Http\RequestHandlers\ModulesAnalyticsPage;
6use Fisharebest\Webtrees\I18N;
7
8/**
9 * @var string $action
10 * @var string $form_fields
11 * @var string $preview
12 * @var string $title
13 */
14
15?>
16
17<?= view('components/breadcrumbs', ['links' => [route(ControlPanel::class) => I18N::translate('Control panel'), route(ModulesAllPage::class) => I18N::translate('Modules'), route(ModulesAnalyticsPage::class) => I18N::translate('Tracking and analytics'), $title]]) ?>
18
19<h1><?= $title ?></h1>
20
21<form method="post" action="<?= e($action) ?>" class="form-horizontal">
22    <?= csrf_field() ?>
23    <?= $form_fields ?>
24
25    <div class="row form-group">
26        <label class="col-sm-3" for="preview">
27            <?= I18N::translate('Preview') ?>
28        </label>
29
30        <div class="col-sm-9">
31            <textarea id="preview" class="form-control" rows="10" dir="ltr" disabled><?= e($preview) ?></textarea>
32        </div>
33    </div>
34
35
36    <div class="row form-group">
37        <div class="offset-sm-3 col-sm-9">
38            <button type="submit" class="btn btn-primary">
39                <?= view('icons/save') ?>
40                <?= I18N::translate('save') ?>
41            </button>
42
43            <a href="<?= e(route(ModulesAnalyticsPage::class)) ?>" class="btn btn-secondary">
44                <?= view('icons/cancel') ?>
45                <?= I18N::translate('cancel') ?>
46            </a>
47        </div>
48    </div>
49</form>
50