One user-friendly touch on Wikipedia is links to PDF documents display an icon at the end of the link, i.e. http://example.org/test.pdf ![Image]()
Source: Help:External link icons - Wikipedia
Has anyone implemented something similar in phpBB's CSS?
Adding the following Wikipedia's CSS coding to the bottom ofGoogle also turned up How to add file-type icons to links with CSS · GitHub which does seem to work although the PDF icon is not in appropriate colour and therefore not quite as obvious to the reader.
Source: Help:External link icons - Wikipedia
Has anyone implemented something similar in phpBB's CSS?
Adding the following Wikipedia's CSS coding to the bottom of
links.css, purging phpBB cache and browser cache does not seem to work for me on my phpBB 3.3.11 test instance. Code:
a[href*=".pdf"].external {background: url("//upload.wikimedia.org/wikipedia/commons/4/4d/Icon_pdf_file.png") no-repeat right;/* @noflip */padding: 8px 18px 8px 0;}Code:
/* For this to work you need to have already included FontAwesome (https://fortawesome.github.io/Font-Awesome/) in your <head>: <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">*/a[href$=".pdf"]:after { font-family: FontAwesome; content: "\00a0\f1c1"; /* 00a0 is a non-breaking space, f1c1 is the pdf symbol */}Statistics: Posted by P_I — Fri Apr 12, 2024 6:02 pm