CSS selector, add image to links by file extension
In the wonderful world of CSS you can use different selector to locate the element you want. Some of them even allow you to filter the element by a certain property. In this example we will use the “href” attribute of the “a” tag to add an image in function of the file type linked.
In other words, if I have a link to a psd file, it will automatically add a little psd icon in front of the link. All of this is done in CSS using selectors.

