zurb-foundation-5
Version:
Foundation 5 for npm (no code modification from original repo)
20 lines (18 loc) • 476 B
HTML
{{#markdown}}
```html
<form data-abide="ajax" id="myform">
<div class="name-field">
<label>Your name <small>required</small>
<input type="text" name="users_name" required pattern="[a-zA-Z]+">
</label>
<small class="error">Name is required and must be a string.</small>
</div>
<button type="submit">Submit</button>
</form>
```
```javascript
$('#myform').on('valid.fndtn.abide', function() {
// Handle the submission of the form
});
```
{{/markdown}}