xref: /webtrees/resources/views/modules/custom-css-js/edit.phtml (revision 701f5d180b85b9d3e0747b6ddc9e9d64dd73d0d6)
1<?php
2
3use Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
4use Fisharebest\Webtrees\I18N;
5
6/**
7 * @var string $body
8 * @var string $head
9 * @var string $title
10 */
11
12?>
13
14<?= view('components/breadcrumbs', ['links' => [route(ControlPanel::class) => I18N::translate('Control panel'), $title]]) ?>
15
16<h1><?= $title ?></h1>
17
18<form method="post">
19    <div class="row mb-3">
20        <label for="head" class="col-sm-3 col-form-label">
21            <?= I18N::translate('Add content to the end of the <code>&lt;head&gt;</code> element.') ?>
22        </label>
23        <div class="col-sm-9">
24            <textarea id="head" name="head" class="form-control font-monospace" dir="ltr" rows="5"><?= e($head) ?></textarea>
25            <p class="text-muted">
26                <?= I18N::translate('Include the <code>&lt;style&gt;&lt;/style&gt;</code> tags.') ?>
27            </p>
28        </div>
29    </div>
30
31    <div class="row mb-3">
32        <label for="body" class="col-sm-3 col-form-label">
33            <?= I18N::translate('Add content to the end of the <code>&lt;body&gt;</code> element.') ?>
34        </label>
35        <div class="col-sm-9">
36            <textarea id="body" name="body" class="form-control font-monospace" dir="ltr" rows="5"><?= e($body) ?></textarea>
37            <p class="text-muted">
38                <?= I18N::translate('Include the <code>&lt;script&gt;&lt;/script&gt;</code> tags.') ?>
39            </p>
40        </div>
41    </div>
42
43    <button type="submit" class="btn btn-primary">
44        <?= view('icons/save') ?>
45        <?= I18N::translate('save') ?>
46    </button>
47
48    <a href="<?= route(ControlPanel::class) ?>" class="btn btn-secondary">
49        <?= view('icons/cancel') ?>
50        <?= I18N::translate('cancel') ?>
51    </a>
52
53    <?= csrf_field() ?>
54</form>
55