Alias content
Last modified: September 19, 2007 - 07:15
In this example you will learn how to activate a module, check for permissions and alias the URL path.
By default, a typical Drupal URL will be www.example.com/?q=node/3 or www.example.com/node/3. While this is useful, Drupal core comes with a module that can make it nicer.
- Navigate to Administer > Site building > Modules
- In the core options module list locate Path module.
Note the description “Allows users to rename URLs.”
- Select the box next to it and select save configuration on the bottom.
- Navigate to Administer > User management > Access control
Note
Many modules add features which often will need to be assigned to your sites roles. By default new features are not enabled for any role. UID1 has access to all your sites features.
- Scroll down to the path module entry. You will see two new permissions
administer URL aliases - this allows an administrator to edit/update aliases create URL aliases - this allows users to alias nodes - Choose the role you wish to grant this ability to and then select save permissions
- You can either create new content or edit a previously created node.
- Scroll down on the edit page and find the collapsed fieldset URL path settings.
- Enter an alias for your content and submit your page.
For this example we'll use test-alias
- You should now be able to browse to your content at www.example.com/test-alias
- Browse to Administer > Site building > URL aliases.
This is where you can edit and add multiple aliases to content. Select the more help... link for some examples of how to alias other Drupal URLs.
