Add description to the Attachments field for "Submit a request" form
Answered
Posted Apr 15, 2016
At the bottom of our "Submit a request" form in our Help Center is an automatic upload form for adding attachments. I would like to add a description similar to the description I've added to my other fields. The problem is, the Attachments field is not accessible in our Ticket Fields Admin Settings so I'm not able to add a description yet I am able to add one to all the other fields (i.e. Subject, etc). Below is an example showing our "Submit a request" form for context.
I looked at the HTML for our Help Center and found there is a template called "New Request Page" with a reference to "{{request_form}}" but I'm not sure how to access that or edit it.
0
83
83 comments
Bobby Kondvilkar
How can we change the description text based on the drop-down values we select? Is it possible to conditionally change the description at the bottom of attachment field?
0
Zachary Bender
I am trying to check for form and a field drop down option is picked. And if those two options are picked then changes the text.
Here has what i have come up with
if(window.location.href.indexOf("123412") > -1 && $('.form-field.request_custom_fields_112313.val() = "Eligibility Letter"') {
$('div#upload-dropzone').parent().find('label').text('Attach copy of Letter (Required)')
}
1
Dane
Multiple attachment fields in a form is not natively available. However, you are able to alter your requests page through the altering of your theme on Guide and could likely achieve a similar result to the change you are looking to make. Please take note that customization of HC code is outside our scope.
0
Jack Harris
Is it possible to either have multiple attachment fields or have the caption change based on which ticket form is being used?
0
Dave Dyson
0
CJ Johnson
1263082116169 No, I'm referring to the code in the comments on this article, for example: https://support.zendesk.com/hc/en-us/community/posts/4409515328538/comments/4409510181018

I have confirmed that jQuery is present in my document_head.hbs .
Here's a screenshot showing that the div id for "upload-dropzone" closes before the attachment text code even appears, which is why it doesn't work:
I just haven't had a chance to figure out how to rewrite the JS to reference this class instead of the div ID.
0
Dave Dyson
0
CJ Johnson
I suspect the code posted in 2020 is no longer valid. The div listed is not where this text field lives, at least not for me.
0
Tipene Hughes
Hi 1265219832349,
While it's not possible to require the attachment field in your help center directly out of the box, here's a great user submitted example of how you could implement a required attachment to your request form:
https://support.zendesk.com/hc/en-us/community/posts/4409515169946-Requiring-a-ticket-attachment-if-a-particular-dropdown-option-is-selected
I hope this helps! Feel free to reach out with any questions.
Tipene
0
Andrii Kozychko
Hey, is this code will work in any way?
I've tried to paste that code to change the "Attachment" field in one of my forms, but it does not work:
Is there any way to make the ticket unsubmittable if the user has not added the attachment?
2
Sign in to leave a comment.