Tips and tricks for the Custom Links module

Last updated on
30 April 2025

You are browsing documentation for an older version of Drupal, which is not supported any longer, and the information may not be correct. See current documentation for Contributed modules

The Custom Links module doesn't have a documentation page. So in the meantime I'm writing these tips here, in the Flag module's handbook.

Custom Links doesn't support showing a link to users belonging to a specific role (e.g., "anonymous users"), so you'll have to use a dirty trick: assign anonymous users, only them, some "silly" permission. Something that's harmless. An easy solution is to install the Site Configuration Permissions, which lets you create a permission.

Then, under Custom Link's "Viewer permission restriction" choose this permission.

(Note: administrators will still see this link.)

Sometimes you want the link to be just a message. You don't want it to be a link pointing anywhere. To do this you'll use another dirty trick:

Say the link's title is "Something I want to tell you". Change it to "</a>Something I want to tell you<a>" and tick the "Title uses HTML" checkbox.

Help improve this page

Page status: Not set

You can: