path.creating_alias.html.twig

Same filename in other branches
  1. 10 core/modules/path/help_topics/path.creating_alias.html.twig
  2. 11.x core/modules/path/help_topics/path.creating_alias.html.twig
---
label: 'Creating a URL alias for a content item'
related:
  - path.overview
  - path.editing_alias
  - node.creating_content
  - node.editing
---
{% set path_permissions_link_text %}
{% trans %}Create and edit URL aliases{% endtrans %}
{% endset %}
{% set path_permissions_link = render_var(help_route_link(path_permissions_link_text, 'user.admin_permissions.module', {'modules': 'path'})) %}
{% set overview_topic = render_var(help_topic_link('path.overview')) %}
<h2>{% trans %}Goal{% endtrans %}</h2>
<p>{% trans %}Give a content item page a human- or SEO-friendly URL alias; you can follow similar steps to create an alias for a taxonomy term page. See {{ overview_topic }} for more about aliases.{% endtrans %}</p>
<h2>{% trans %}Who can create URL aliases?{% endtrans %}</h2>
<p>{% trans %}Users with the <em>{{ path_permissions_link }}</em> permission can create aliases. To follow the steps in this topic, you will also need permission to edit the content item.{% endtrans %}</p>
<h2>{% trans %}Steps{% endtrans %}</h2>
<ol>
  <li>{% trans %}Locate and open the content edit form for the content item, or create a new content item (see related topics on creating and editing content).{% endtrans %}</li>
  <li>{% trans %}Under <em>URL alias</em> on the edit form, enter the desired alias (for example, "/about-us"). Make sure the alias starts with a "/" character.{% endtrans %}</li>
  <li>{% trans %}Click <em>Save</em>.{% endtrans %}</li>
  <li>{% trans %}Verify that the page can be visited with the new alias, for example <em>https://example.com/about-us</em>.{% endtrans %}</li>
</ol>
<h2>{% trans %}Additional resources{% endtrans %}</h2>
<ul>
  <li><a href="https://www.drupal.org/docs/user_guide/en/content-create.html">{% trans %}User guide: Creating a Content Item{% endtrans %}</a></li>
</ul>

File

core/modules/help_topics/help_topics/path.creating_alias.html.twig

View source
  1. ---
  2. label: 'Creating a URL alias for a content item'
  3. related:
  4. - path.overview
  5. - path.editing_alias
  6. - node.creating_content
  7. - node.editing
  8. ---
  9. {% set path_permissions_link_text %}
  10. {% trans %}Create and edit URL aliases{% endtrans %}
  11. {% endset %}
  12. {% set path_permissions_link = render_var(help_route_link(path_permissions_link_text, 'user.admin_permissions.module', {'modules': 'path'})) %}
  13. {% set overview_topic = render_var(help_topic_link('path.overview')) %}
  14. <h2>{% trans %}Goal{% endtrans %}</h2>
  15. <p>{% trans %}Give a content item page a human- or SEO-friendly URL alias; you can follow similar steps to create an alias for a taxonomy term page. See {{ overview_topic }} for more about aliases.{% endtrans %}</p>
  16. <h2>{% trans %}Who can create URL aliases?{% endtrans %}</h2>
  17. <p>{% trans %}Users with the <em>{{ path_permissions_link }}</em> permission can create aliases. To follow the steps in this topic, you will also need permission to edit the content item.{% endtrans %}</p>
  18. <h2>{% trans %}Steps{% endtrans %}</h2>
  19. <ol>
  20. <li>{% trans %}Locate and open the content edit form for the content item, or create a new content item (see related topics on creating and editing content).{% endtrans %}</li>
  21. <li>{% trans %}Under <em>URL alias</em> on the edit form, enter the desired alias (for example, "/about-us"). Make sure the alias starts with a "/" character.{% endtrans %}</li>
  22. <li>{% trans %}Click <em>Save</em>.{% endtrans %}</li>
  23. <li>{% trans %}Verify that the page can be visited with the new alias, for example <em>https://example.com/about-us</em>.{% endtrans %}</li>
  24. </ol>
  25. <h2>{% trans %}Additional resources{% endtrans %}</h2>
  26. <ul>
  27. <li><a href="https://www.drupal.org/docs/user_guide/en/content-create.html">{% trans %}User guide: Creating a Content Item{% endtrans %}</a></li>
  28. </ul>

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.