Tagged: upload error
-
AuthorPosts
-
March 31, 2022 at 7:59 pm #1346768
I can not upload a .ico file to use as a favicon.
I get an error message saying it’s not allowed to upload these files?
What can be wrong? It should be no problem to upload a .ico file, right?
April 1, 2022 at 6:07 am #1346820Hi Alwin,
WordPress restricts the type of files you can upload, you can find the list here: https://codex.wordpress.org/Uploading_Files
In order to allow .ico files to be uploaded, edit wp-config.php file located in the root folder of your site (you can view this using FTP or through Cpanel).
Find this line of text in wp-config.php file:/* Add any custom values between this line and the "stop editing" line. */
below it add this code:
define( 'ALLOW_UNFILTERED_UPLOADS', true );
Hope this helps.
Best regards,
NikkoApril 1, 2022 at 11:47 am #1346850Hello Niko,
Thank you for your help.
The point however is that .ico files are allowed (see the link you provided yourself):
https://codex.wordpress.org/Uploading_FilesWordPress supports uploading the following file types:
.jpg
.jpeg
.png
.gif
.icoIn the past I could always upload .ico files without any problems, and it should be no problem now either. But it is, so how to proceed now?
Thanks,
AlwinApril 1, 2022 at 1:40 pm #1346877Hi Alwin,
I’m not sure if WordPress forgot to remove it from the list or it is allowed by default however, I did try upload a .ico file on my end and I get this error:
“icon.ico” has failed to upload. Sorry, you are not allowed to upload this file type.
So my assumption is that it is not allowed, please proceed to editing wp-config.php file as instructed above since it’s working properly and I have also tested it.
Best regards,
NikkoApril 1, 2022 at 3:11 pm #1346904Hello Nikko,
I used a .png file for the favicon and that’s working fine now :)
Thanks,
AlwinApril 1, 2022 at 5:53 pm #1346920Hi,
Great, I’m glad that you got it working. Please let us know if you should need any further help on the topic or if we can close it.
Best regards,
RikardApril 1, 2022 at 5:55 pm #1346922Yes, you can close this topic.
April 1, 2022 at 7:57 pm #1346928Hi,
Thanks for letting us know, I’ll close this thread for now then. Please open a new thread if you should have any further questions or problems.
Best regards,
Rikard -
AuthorPosts
- The topic ‘upload warning .ico file’ is closed to new replies.