Answer the question
In order to leave comments, you need to log in
How to change the template for a specific Drupal 7 page?
Hello comrades!
I'm still getting to grips with Drupal 7. Now I have a question that was asked in the Topic Title. I realized that if you put the file page--front.tpl.php next to page.tpl.php (which sets the main canvas for displaying all pages of the site) , then you can cover the main page with a completely different design.
But how do you make sure that you can apply a different design to 1 of the regular pages on your site that have links like www.example.com/node/3 ?
Thank you for your help on my path to enlightenment)
Answer the question
In order to leave comments, you need to log in
Theming of a specific page
Go to the template folder (your_site/sites/all/themes/your_template/tempalates).
Copy the page.tpl.php file to page--node_number/page_address.tpl.php.
We edit the created file for our needs.
Clearing the cache on the site.
How much does the design need to change? If this can be done with CSS, then the code is simpler
There is also a Panels
module , but this is for creating a node with a special blocking.
З.ы I apologize for 2 posts, when I tried to save edits, I got the answer: “You cannot edit this material” =(
Information on redefining pages can be found here drupal.org/node/1089656
Here, if you need to redefine the theme for the page www.example.com/node/3 , create a file in the theme folder page--node--3.tpl.php.
Drupal tutorials can be found here:
buildamomodule.com/
www.lullabot.com/
drupalize.me/
www.lynda.com/search?q=drupal&x=-1371&y=-42
How did you hear about page--front.tpl.php ? There is also about the rest - in the documentation Drupal 7 Template (Theme Hook) Suggestions http://drupal.org/node/1089656#page-suggestion : page--[front|internal/path].tpl.php
...
page--node--edit.tpl.php
page--node--1.tpl.php
page--node.tpl.php
page.tpl.php
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question