Part on Useful names and conventions finished
This commit is contained in:
parent
20aee0812f
commit
d907e90218
7 changed files with 18 additions and 18 deletions
42
views/notes/create.view.php
Normal file
42
views/notes/create.view.php
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
<?php require('views/partials/head.php') ?>
|
||||
<?php require('views/partials/nav.php') ?>
|
||||
<?php require('views/partials/banner.php') ?>
|
||||
<main>
|
||||
<div class="mx-auto max-w-7xl py-6 sm:px-6 lg:px-8">
|
||||
<div>
|
||||
<div class="md:grid md:grid-cols-3 md:gap-6">
|
||||
<div class="mt-5 md:col-span-2 md:mt-0">
|
||||
<form method="POST">
|
||||
<div class="shadow sm:overflow-hidden sm:rounded-md">
|
||||
<div class="space-y-6 bg-white px-4 py-5 sm:p-6">
|
||||
|
||||
<div>
|
||||
<label for="body" class="block text-sm font-medium text-gray-700">Body</label>
|
||||
<div class="mt-1">
|
||||
<textarea
|
||||
id="body"
|
||||
name="body"
|
||||
rows="3"
|
||||
class="mt-1 block w-full rounded-md border-gray-300 shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm"
|
||||
placeholder="Here is an idea for a note."
|
||||
//required
|
||||
><?= $_POST['body'] ?? '' ?>
|
||||
</textarea>
|
||||
<?php if (isset($errors['body'])) : ?>
|
||||
<p class="text-red-500 text-xs mt-2"><?= $erros['body'] ?></p>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bg-gray-50 px-4 py-3 text-right sm:px-6">
|
||||
<button
|
||||
type="submit"
|
||||
class="inline-flex justify-center rounded-md border border-transparent bg-indigo-600 py-2 px-4 text-sm font-medium text-white shadow-sm hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2">Save</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
<?php require('views/partials/footer.php') ?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue