Menu Close

Get Support From ShopWired Close

All systems fully operational

Subscribe To Updates
Prefer To Live Chat? Chat directly with ShopWired support Available from 9.00am to 6.00pm Monday to Friday Quickest response time
Send A Message
Response within 24 hours

Menu Close

Menu

Custom contact form

If you'd like visitors to your website to be able to complete a contact form, the results of which are then sent to you by email, you'll need to create a custom contact form.

1. The form action should be the URL of the page that you are creating the form to display on, e.g.

<form action="/some-url-here">

The method attribute should be post, e.g.

method="post"

You can include enctype="multipart/form-data" if the form includes a field for your users to upload a file.

For example,

<form action="/some-url-here" method="post" enctype="multipart/form-data">

2. Fields in the form can be constructed in normal HTML, e.g.

<input name="email_address" type="text">

3. If including a file attachment within the form this must have a name of "attachment", e.g.

<input name="attachment" type="file">

4. You must also include the following code within the <form> tag

For Version 1 and Version 2 themes:

{{ shopwired.custom_form({ 
    'to_email': '', 
    'from_email': '', 
    'redirect_url': '', 
    'subject': '' 
}) }}

For Version 3, Version 4 and Version 5 themes:

{{ theme.custom_form({ 
    'to_email': '', 
    'from_email': '', 
    'redirect_url': '', 
    'subject': '' 
}) }}

to_email is the email address you want to receive the email at

from_email is the email address that the email should be sent from

subject is the subject line of the email that is generated once the form is completed

redirect_url is the URL that your visitor should be redirected to once they complete the form

success_message can be set instead of a redirect_url in order to keep the user on their current page

for example

{{ theme.custom_form({ 
    'to_email': 'info@joesshoeshop.com', 
    'from_email': 'info@joesshoeshop.com', 
    'redirect_url': '/thanks', 
    'subject': 'new website enquiry' 
}) }}

Important!

If reCAPTCHA is installed in your ShopWired account, you must add reCAPTCHA to all custom forms. For guidance on installation of reCAPTCHA please read here.