Recent searches


No recent searches

Hidding the CC field on a contact form

Answered


Posted Dec 04, 2023

For some reason on a new form, both a CC field and Organization field are both showing up. I cannot find a way to remove them in the admin center, but I would like to hide, at least the CC field. The below lines have disabled the field and hidden the label, but there is still a visible text box that cannot be edited and it looks like butt. How might I be able to hide this unsightly thing from my users? The field is contained in this snippet:

<ul tabindex="-1" data-hc-pills-container="true" data-hc-focus="false"><li><span style="display: none; width: auto; white-space: nowrap;">Add emails</span><input type="text" id="request_collaborators_" value="" autocomplete="off" aria-required="false" aria-describedby="request_collaborators_error" style="display: none; width: 122.6px;" placeholder="Add emails" size="23"></li></ul>


  $('#request_collaborators_').hide(); // hide the CC button
  $('ul[data-hc-pills-container=true][tabindex=-1]').hide();
  $('.form-field label:contains("CC")').hide();

1

2

2 comments

Ahmed Zaid

We have reasons in our instance to allow people to cc on tickets and want to keep that on. Hiding the field seems like the best option. Also, this box and the organization box only appear on this form and not any of our other forms… why is that?

0


Ahmed Zaid

I figured it out last night. We were seeing this when previewing a theme before making it live. I didn't put together that the preview was displaying as an authenticated user. We don't make our guides visitors authenticate, and when I tried making the theme live, those two fields are no longer visible when viewing as a normal user.

 

 

0


Please sign in to leave a comment.

Didn't find what you're looking for?

New post