walsgit / external-links-in-new-tab
Opens all external links in a new tab
Package info
github.com/WalsGit/external-links-in-new-tab
Type:flarum-extension
pkg:composer/walsgit/external-links-in-new-tab
Fund package maintenance!
2.2.1
2026-10-18 21:25 UTC
Requires
- flarum/core: ^2.0.0
Requires (Dev)
- flarum/testing: ^2.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-10-18 21:26:08 UTC
README
A Flarum extension.
Opens all external links in a new tab:
- Links inside posts are handled on the backend (
target="_blank" rel="noopener noreferrer"is added when posts are rendered). - Other external links on the forum frontend (menus, navigation bar, etc.) are opened in a new tab on click event.
- When Flarum is installed in a subfolder (example.tld/flarum), links to other paths (example.tld/blog) are considered external.
Versions
Starting with the version 2.0.0 of this extension, it will only be compatible with Flarum v2.*.
Latest version of the extension compatible with Flarum v1.8.* is walsgit/external-links-in-new-tab:"1.2.0".
Installation
Install with composer:
composer require walsgit/external-links-in-new-tab:"*"
Updating
composer update walsgit/external-links-in-new-tab:"*"
php flarum cache:clear
Notes
- Thanks to @luceos for pointing out another way of doing this (version 2.2.0).
- Made with the help of AI.