Hello Friends, we are here with our latest tutorial, in we are going to tell you easiest method to Add attachment File type Icons in WordPress.

Have you seen websites that show file icons next to the download? Most of noobs in blogging always searching how to setup this without performing any coding. if it was possible to display attachment file icons in WordPress. Yes it is, and it’s quite easy. If you want to do this then you are at right place.
When You Need Attachment File Icons in WordPress

By default, WordPress allows you to upload some file formats eg. images, audio, video, and other documents. 

Read More: You can also allow additional file types to be uploaded in WordPress.

When you try to upload a supported file format WordPress embed it perfectly in its deserving manner and  for all other files formats it will just give file name with text only and it will give redirect link  to the download or attachment page.

In this upper screenshot, there are 2 files with different file format that WordPress doesn’t support, for user it get more difficult to choose required file format.

For helpfull post for user, then you may want to display an file format icon next to the link, so your users can easily find the file type they’re looking for.

Having said that, let’s see how to add attachment file icons in WordPress for different file types.

Method 1:
Add Attachment File Icons in WordPress Using Plugin

Step 1: First thing you need to do is install and activate the MimeTypes Link Icons pluginDownload

Read More:  How to install a WordPress plugin.

Step 2:  Visit Settings » MimeType Icons page to configure plugin settings.

Step 3: The plugin allows you to get choose file type of icon,size and help you in alignment on the page.

Extra: Under the advanced options, you can enable CSS classes to hide icons. File download links wrapped in these CSS classes will not show the icons.

Here you get multiple options for more functionality

Don’t forget to click on the Save Changes button to store your settings.

You can now edit a post or page and add an file download link using media uploader. Preview your post and you will see the file icon next to the download link.

Now we are done!!!!!!! You will see the icon of file format.

Method 2: Using Icon Fonts for Attachment Files in WordPress.

In this Method, we will use Icon Font to display file format icon of file.

Step 1: First thing you need to do is install and activate the Better Font Awesome plugin. DOWNLOAD

Upon activation, You will get a new ‘Insert Icon’ button on top of post editor. Clicking on it will display a popup where you can search and select the icon you want to add.
Font Awesome comes with best different style file type icons 

Step 2:  Click on the icon you want to add and the plugin will automatically add the required shortcode in the post editor.

Step 3: Now you can upload your file and insert into post using media uploader.

 Extra: You can also add or customise CSS according your preference and file icon by adding your own css class to the shortcode like this:

[icon name=”file-pdf-o” class=”” unprefixed_class=”pdf-icon”]

You can now use .pdf-icon class to change icon size, color, and style it to your own needs.

Thanks for reading the post also don’t forget to suggest errors in comment section.

We hope this article helped you in learning, How to add attachment file icons in WordPress?

Like, Share and subscribe.

Keep visiting for more tech updates.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s