zen theme’s page-front.tpl

Copy all the code from your page.tpl.php, create a new file called page-default.tpl.php and paste the code in there.
Now delete all the code from your page.tpl.php and add the following:

** 將 page.tpl.php內容copy到新的檔案: page-default.tpl.php

**將下面內容取代原本page.tpl.php

**新增您要的 page-front.tpl.php (可以先將page.tpl.php 複製成 page-front.tpl.php, 然後再修改成自己要的首頁)

<?php
// Loads the front page template
if ($is_front) {
include
'page-front.tpl.php';
return; }

//Adding custom template based on content types
if ($node->type=='story') {
include
'page-story.tpl.php';
return; }

//if none of the above applies, load the page-default.tpl.php
include 'page-default.tpl.php';
return;
?>

Don’t forget copy page.tpl.php to page-story.tpl.php

http://drupal.org/node/296111

Share and Enjoy:
  • Print
  • Digg
  • StumbleUpon
  • del.icio.us
  • Facebook
  • Yahoo! Buzz
  • Twitter
  • Google Bookmarks
  • MySpace
  • Plurk
  • RSS
  • Google Buzz
  • Live
本篇發表於 themes。將永久鏈結加入書籤。

發表迴響

你的電子郵件位址並不會被公開。 必要欄位標記為 *