The filelinks package allows you to insert tags into content in place of actual anchor links. This is useful when you frequently update files on the system or have the link to a particular file on mutliple pages. Change the file associated with a filelink tag and all pages affected will automatically display the new link.

Filelinks Package

This consists of:

  • Filelinks component - used to create and manage filelinks
  • Filelink content plugin - converts filelink tags to actual links within content
  • Filelinks editors-xtd plugin - popup to insert tags in editor
  • Filelinks system plugin - optional plugin to remove tag code from finder search results

  Filelinks Packagev3.6.2

v3.6.2

  • [ADD] Now possible to output filelink description
  • [BUG] filelinks tag removed from content (but not title) when finder indexes content - previously searching for the word filelinks found every page with a tag on it.

v3.6.1

  • [BUG] php warning when trying to save duplicate filelink
  • [BUG] possible to link the same file twice if in a different category
  • [ADD] language strings for exceptions

v3.6.0

  • [ADD] Enhanced filelink stats to show not only filelinks within content, category descriptions and custom modules but where the file has been used in an anchor element.

v3.5.0

  • Initial release

 

Configuration

Component 

The Filelinks component relies upon the settings for the Media component and also the FileSystem - Local plugin, so these should be configured first.

It is best to create another directory to hold all the files, rather than upload them to the images directory. In this case I chose to create a files directory and added it to the FileSystem - Local plugin.

Next goto Media: Options and set the path to the Files Folder - in this case: files and also the Allowed Extensions and Legal Document extensions. See example below.

media options

Finally go to Filelinks components configuration and set some icons and css if you wish to output file icons. This step is purely optional. If you are using Fontawesome then a good starting point for any file type is to look at the Font Awesome page and look for icons starting fa-file

Below is an example:

icon css

Content Plugin

Tip: search for filelink in plugins to find all three.

Enable this plugin in order to replace filelinks tags within content. The only option currently is whether to show the file version, if it has been set.

filelink plugin options

Editors-xtd Plugin

This has no options but should be enabled. It makes inserting tags in the editor foolproof.

System Plugin

If you choose to use this please enable the plugin and set the Search menu page item. It will remove the filelinks tags from the Search page and replace them with the link text.

filelinks system plugin options

Note that if you order it before the Articles Anywhere plugin it wil remove the Articles Anywhere tags as well. If this is not the desired behaviour then order after that plugin.

TODO
  • Option to remove Articles Anwhere tag or not.
  • Option to replace with file anchor, and with templated output.

Usage Notes

License

GNU General Public License version 2 or later; see GPLv2