Add: configuration to contact form

This commit is contained in:
Aroy-Art 2022-03-19 15:34:52 +01:00
parent e75e08c946
commit fc6d5e0dd3
Signed by: Aroy
GPG key ID: DB9689E9391DD156

View file

@ -14,31 +14,37 @@
</div>
</div>
{{"<!-- /Title -->" | safeHTML}}
{{ with .contact_form }}
{{ if .h_captcha.enable }}
<script src="https://js.hcaptcha.com/1/api.js" async defer></script>
<form name="contact" method="post" action="/thank-you/" data-netlify="true">
{{ end }}
<form name="contact" method="post" action="{{ .action }}" data-netlify="{{ .netlify }}">
<input type="hidden" name="form-name" value="contact" />
<h3 class="text-center">Drop Me a Message</h3>
<h3 class="text-center">{{ .content }}</h3>
<div class="row">
<div class="d-flex flex-column col-md-4 justify-content-between">
<input id="contact-form-name" type="text" name="Name" class="form-control" placeholder="Your Name *" value="" required="true" autocomplete="off" />
<input id="contact-form-email" type="email" name="Email" class="form-control" placeholder="Your Email *" value="" required="true" autocomplete="off" />
<input id="contact-form-subject" type="text" name="Subject" class="form-control" placeholder="Subject *" value="" required="true" autocomplete="off"/>
<input id="contact-form-name" type="text" name="Name" class="form-control" placeholder="{{ .name }}" value="" required="true" autocomplete="off" />
<input id="contact-form-email" type="email" name="Email" class="form-control" placeholder="{{ .email }}" value="" required="true" autocomplete="off" />
<input id="contact-form-subject" type="text" name="Subject" class="form-control" placeholder="{{ .subject }}" value="" required="true" autocomplete="off"/>
</div>
<div class="d-flex flex-column col-md-8">
<textarea id="contact-form-message" class="form-control" placeholder="What's up?" required="true" rows="6"></textarea>
<textarea id="contact-form-message" class="form-control" placeholder="{{ .message }}" required="true" rows="6"></textarea>
</div>
</div>
<div class="row">
<div class="col text-center">
{{ if .h_captcha.enable }}
<div class="col">
<div class="h-captcha" data-theme="dark" data-sitekey="7e9fcbed-3001-42cb-a416-0966c3d9123f"></div>
<div class="h-captcha" data-theme="{{ .h_captcha.theme }}" data-sitekey="{{ .h_captcha.sitekey }}"></div>
</div>
{{ end }}
<div class="col">
<input id="form-submit" type="submit" name="Submit" class="btn btn-light" value="Submit" />
</div>
</div>
</div>
</form>
{{ end }}
</div>
</section>
{{"<!-- /Contact Section -->" | safeHTML}}