Edit Page fixes
This commit is contained in:
@@ -3,59 +3,90 @@
|
||||
{% block content %}
|
||||
<h2>Edit Page - {{ title }}</h2>
|
||||
|
||||
<form method="post" action="/novaconium/savePage">
|
||||
<form method="post" action="/novaconium/savePage" id="edit-page-form-novaconium">
|
||||
|
||||
<input type="hidden" name="id" value="{{ rows.id }}">
|
||||
<input type="hidden" name="token" value="{{ token }}">
|
||||
|
||||
<label for="title">Title:</label>
|
||||
<input type="text" id="title" name="title" value="{{ rows.title }}" required>
|
||||
<div class="form-group">
|
||||
<label for="title">Title:</label>
|
||||
<input type="text" id="title" name="title" value="{{ rows.title }}" required>
|
||||
</div>
|
||||
|
||||
<label for="heading">Heading:</label>
|
||||
<input type="text" id="heading" name="heading" value="{{ rows.heading }}">
|
||||
<div class="form-group">
|
||||
<label for="slug">
|
||||
Slug: (<a href="/page/{{ rows.slug }}" target="_new">/page/{{ rows.slug }}</a>)
|
||||
</label>
|
||||
<input type="text" id="slug" name="slug" value="{{ rows.slug }}" required>
|
||||
</div>
|
||||
|
||||
<label for="description">Description:</label>
|
||||
<input type="text" id="description" name="description" value="{{ rows.description }}">
|
||||
<div class="form-group fullwidth">
|
||||
<label for="body">Body:</label>
|
||||
<textarea id="body" name="body" rows="10">{{ rows.body }}</textarea>
|
||||
</div>
|
||||
|
||||
<h2>Metadata</h2>
|
||||
|
||||
<label for="keywords">Keywords:</label>
|
||||
<input type="text" id="keywords" name="keywords" value="{{ rows.keywords }}">
|
||||
<div class="form-group">
|
||||
<label for="description">Description:</label>
|
||||
<input type="text" id="description" name="description" value="{{ rows.description }}">
|
||||
</div>
|
||||
|
||||
<label for="author">Author:</label>
|
||||
<input type="text" id="author" name="author" value="{{ rows.author }}">
|
||||
<div class="form-group">
|
||||
<label for="keywords">Keywords:</label>
|
||||
<input type="text" id="keywords" name="keywords" value="{{ rows.keywords }}">
|
||||
</div>
|
||||
|
||||
<label for="slug">Slug: (<a href="/page/{{ rows.slug }}" target="_new">/page/{{ rows.slug }}</a>)</label>
|
||||
<input type="text" id="slug" name="slug" value="{{ rows.slug }}" required>
|
||||
<div class="form-group">
|
||||
<label for="author">Author:</label>
|
||||
<input type="text" id="author" name="author" value="{{ rows.author }}">
|
||||
</div>
|
||||
|
||||
<label for="path">Path:</label>
|
||||
<input type="text" id="path" name="path" value="{{ rows.path }}">
|
||||
<h2>CMS Info</h2>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="path">Path:</label>
|
||||
<input type="text" id="path" name="path" value="{{ rows.path }}">
|
||||
</div>
|
||||
|
||||
<label for="intro">Intro:</label>
|
||||
<textarea id="intro" name="intro" rows="5">{{ rows.intro }}</textarea>
|
||||
<div class="form-group">
|
||||
<label for="changefreq">Change Frequency:</label>
|
||||
<select id="changefreq" name="changefreq">
|
||||
{% set freqs = ['always', 'hourly', 'daily', 'weekly', 'monthly', 'yearly', 'never'] %}
|
||||
{% for freq in freqs %}
|
||||
<option value="{{ freq }}" {% if rows.changefreq == freq %}selected{% endif %}>
|
||||
{{ freq|capitalize }}
|
||||
</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<label for="body">Body:</label>
|
||||
<textarea id="body" name="body" rows="10">{{ rows.body }}</textarea>
|
||||
<div class="form-group">
|
||||
<label for="priority">Priority (0.0 - 1.0):</label>
|
||||
<input type="number" id="priority" name="priority" value="{{ rows.priority }}" step="0.1" min="0" max="1">
|
||||
</div>
|
||||
|
||||
<label for="notes">Notes:</label>
|
||||
<textarea id="notes" name="notes" rows="5">{{ rows.notes }}</textarea>
|
||||
<div class="form-group fullwidth">
|
||||
<label for="notes">Notes:</label>
|
||||
<textarea id="notes" name="notes" rows="5">{{ rows.notes }}</textarea>
|
||||
</div>
|
||||
|
||||
<label for="draft">
|
||||
<input type="checkbox" id="draft" name="draft" value="1" {% if rows.draft %}checked{% endif %}>
|
||||
Save as Draft
|
||||
</label>
|
||||
<h2>Page Data</h2>
|
||||
<div class="form-group">
|
||||
<label for="heading">Heading:</label>
|
||||
<input type="text" id="heading" name="heading" value="{{ rows.heading }}">
|
||||
</div>
|
||||
|
||||
<label for="changefreq">Change Frequency:</label>
|
||||
<select id="changefreq" name="changefreq">
|
||||
{% set freqs = ['always', 'hourly', 'daily', 'weekly', 'monthly', 'yearly', 'never'] %}
|
||||
{% for freq in freqs %}
|
||||
<option value="{{ freq }}" {% if rows.changefreq == freq %}selected{% endif %}>{{ freq|capitalize }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
|
||||
<label for="priority">Priority (0.0 - 1.0):</label>
|
||||
<input type="number" id="priority" name="priority" value="{{ rows.priority }}" step="0.1" min="0" max="1">
|
||||
<div class="form-group fullwidth">
|
||||
<label for="intro">Intro:</label>
|
||||
<textarea id="intro" name="intro" rows="5">{{ rows.intro }}</textarea>
|
||||
</div>
|
||||
|
||||
<p><strong>Created:</strong> {{ rows.created|date("Y-m-d H:i:s") }}</p>
|
||||
<p><strong>Last Updated:</strong> {{ rows.updated|date("Y-m-d H:i:s") }}</p>
|
||||
|
||||
<button type="submit">Save Changes</button>
|
||||
|
||||
</form>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user