(PHP) Drupal 7: custom template based on url alias

This will give you zykast. the ability to create custom node templates based on the URL alias of a page.

Example: if you create a page with the URL alias “aboutus”, you can now use node–page-aboutus.tpl.php as your node template.

  • Posted by on January 1st, 1970

This entry was posted in PHP and tagged , , , , , , . Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

Your email is never published nor shared. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Why ask?