Saturday, August 24, 2013

How to Add (PDF) text after links that go to PDFs

We can add " (PDF) " Text  after all links that go to PDFs, this will help users to know easily links that go to PDFs files.

Here CSS Code snippet:

/* Add " (PDF)" text after links that go to PDFs */
a[href$=".pdf"]:after { content: " (PDF)"; }

Result: 

Download Here (PDF)
Disqus Comments