This module does smart aliasing for content types selected by admin under Smart Alias settings form.
This module appends node id to whatever path alias node has like this {path-alias}-{node-id}
.
This means every node's url will contain -nid
at the and of the url.
Also every request which contains dash followed by node id will resolve to the node alias itself.
Here is an example:
whatever-123
will resolve to the alias ofnode/123
-123
will resolve to the alias ofnode/123
- If not alias, then it will resolve to
node/123
- Install module as a standard Drupal module.
- Enable smart aliasing for content types under
/admin/config/search/path/smart-alias
This module depends on Pathauto Drupal module
composer install
# PHP Code standards audit (Coder, DrupalStrict, etc.)
composer run phpcs
# PHP Copy-paste detection
composer run phpcpd
# Run all code audits
composer run audit