function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
honda57honda57 

Pre-Chat form- How can I make my data inputs required?

I used the Pre-Chat code sample form provided here in the developer forums, but I would like to make my field inputs required.  Is this possible?
Here is my current code.  As you can see I have added required="True" to the attributes of each input, yet the form is still not requiring the data.

 <!-- Detail inputs -->
        <div class="input-area">
            <input type="text" placeholder="First Name*" name="liveagent.prechat:leadFirstName" onchange="javascript: document.getElementById('prechat_field').value=this.value;" required="TRUE"/><br />
            <input type="text" placeholder="Last Name*" name="liveagent.prechat:leadLastName"  required="TRUE"/><br />
            <input type="text" placeholder="Company*" name="liveagent.prechat:leadCompany"  required="TRUE"/><br />
            <input type="text" placeholder="Email*" id="contactEmail" name="liveagent.prechat:leadEmail"  required="TRUE"/><br />
            <input type="text" placeholder="Phone" name="liveagent.prechat:leadPhone"/><br />
        </div>