Skip Navigation
Expand
File Extension Type restrictions when creating incident from Ask a Question page
Answer ID 4686   |   Last Review Date 11/24/2021

How do you restrict file extension types when customers create an incident on the Ask a Question page?

Environment: 

Customer Portal, File Attachments

Resolution:

In Customer Portal, there is a 'valid_file_extensions' attribute in the 'FileAttachmentUpload2' widget where you can define a list of accepted file extensions without leading periods and separated by commas. Please note, the 'valid_file_extensions' default for the attribute is defined by all extensions.

You can edit this widget by going to the path below:

Customer Portal v3.x:

standard/input/FileAttachmentUpload

Example:
<rn:widget path="input/FileAttachmentUpload" valid_file_extensions="gif,pdf,doc"

Customer Portal v2.x:

standard/input/FileAttachmentUpload2

 

To edit widgets, you will need to access to Customer Portal first. For more information about Customer Portal, please see Overview of Customer Portal section in documentation.

To access to your Customer Portal, you’ll also need a WebDAV client for downloading and uploading files. Please see Answer 2600: Configuring WebDAV connection to access the Customer Portal or Answer 4704: Popular Answers About WebDAV for more information about using WebDAV. 

The widget can be found in file:  cp/customer/development/views/pages/ask.php

Available Languages for this Answer:

Notify Me
The page will refresh upon submission. Any pending input will be lost.