All Collections
FAQ's and Troubleshooting
Hiding contact form title on successful submission
Hiding contact form title on successful submission

Hide contact form title upon submit

Showhan Ahmed avatar
Written by Showhan Ahmed
Updated over a week ago

Currently, we don't have any options to hide the title of the contact form. This is the title being referred to.

To remove the title, we can use the following script in Divi β†’ Theme Options β†’ Integration Tab β†’ Add code to the < head > of your blog field.

<script> 
(function($) {
$(document).ready(function() {
$(document).on('click', '.et_pb_contact_submit', function() {
var clickedBtn = $(this);
var thisForm = clickedBtn.closest('.et_pb_contact_form_container');
$(document).ajaxComplete(function() {
if (!thisForm.find('.et-pb-contact-message').is(':empty')) {
thisForm.find('.et_pb_contact_main_title').hide();
}
});
});
});
})(jQuery);
</script>

It will remove the form title once it is successfully submitted and the success message shows.

Did this answer your question?