0

If i override page.tpl.php to page--front.tpl.php which is working for only front page of site. But i want that overrided .tpl file should work for other urls as well. how can i create ? is there any other filename suggestion which i can use ?

  • More than likely whatever theme your using it will be page.tpl.php – Leigh Sep 18 at 12:05
  • okay, but i have created .tpl file in my module folder and that i want to use in all pages and don't want to implement that file in current theme, just want to override – Lokesh1024 Sep 18 at 12:13
  • basically i have created a module which contains .tpl files and those are overriding the theme folders .tpl files and i couldn't manage to override page.tpl file which is working for all pages. – Lokesh1024 Sep 18 at 12:23
  • Your page.tpl.php will work for all pages except the ones that have their own page template defined, for example page--front.tpl.php. See drupal.org/docs/7/theming/… and also see drupal.org/docs/7/theming/… for adding your own template suggestions based on content type for example. From there it's just a small step to have templates suggested based on the current URL. – leymannx Sep 18 at 12:42
  • Okay. thank you Leigh and @leymannx – Lokesh1024 Sep 18 at 13:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.