Vinay Jose
Create new.html
259598c unverified
{% extends 'layout.html' %}
{% block content %}
<form action="/contacts/new" method="post">
<fieldset>
<legend>Contact Info</legend>
<p>
<label for="email">Email</label>
<input name="email" id="email" type="text" placeholder="Email" value="{{ contact.email or '' }}"/>
<span class="error">{{ contact.errors['email'] }}</span>
</p>
<p>
<label for="first">First Name</label>
<input name="first" id="first" type="text" placeholder="First Name" value="{{ contact.first or '' }}"/>
<span class="error">{{ contact.errors['first']}}</span>
</p>
<p>
<label for="last">Last Name</label>
<input name="last" id="last" type="text" placeholder="Last Name" value="{{ contact.last or '' }}"/>
<span class="error">{{ contact.errors['last'] }}</span>
</p>
<p>
<label for="phone">Phone</label>
<input name="phone" id="phone" type="text" placeholder="Phone" value="{{ contact.phone or '' }}"/>
<span class="error">{{ contact.errors['phone'] }}</span>
</p>
<button>Save</button>
</fieldset>
</form>
<p>
<a href="/contacts">Back</a>
</p>
{% endblock %}