Purchase a license: $65

Full refunds available within 30 days.

EE2 + compatible

Questions + support for purchased licenses: support@buildwithstructure.com


Linking to an External Page or FIle in Navigation

Category: Techniques

You can have pages link offsite or even to files using the following method:

  1. Create a new template called “external_link” with a PHP redirect and the custom field name for the URL value (PHP code below)
  2. Allow this template to use PHP under the template preferences
  3. Make a new channel named “External Link” with a custom field that is either a text field (to input a URL offsite) or a file upload field (to link to a PDF, Word doc, etc)
  4. Make this channel managed by Structure under the module channel settings and set the default template to your new “external_link” template
  5. Assign a new page to this new channel (named the exact same title if desired) and upon visiting you will be redirected to the external page or file

     header( "Location: {exp:channel:entries}{your_link_field}{/exp:channel:entries}" );

Note: Make sure your channel has ‘Automatically turn URLs and email addresses into links?’ turned off under the channel settings

« All Documentation