2011-02-11 37 views
0

在WordPress中,我試圖在不同的頁面上使用兩個不同的主題(現代派和Tanzaku)。我使用現代主義作爲我的基本主題,並希望使用Tanzaku對一個頁面進行樣式/格式化,並返回具有指定類別的博客條目。如何檢查不加載正確內容的wordpress php文件?

因此,我做了以下內容:

  1. 更新現代的的functions.php與Tanzaku的functions.php文件。
  2. 創建contest.php文件並放入Tanzaku的index.php文件,並做了一些編輯。
    • 取出並插入頁眉
    • 拿出頁腳和下頁屬性與
  3. 添加更換了新的一頁「大賽」的頁面下,更新的模板,然後將其設置爲我之前創建的contest.php文件這一步。

但是,我的PHP頁面只加載?

// [grid column setting] $col_w = 290; 
// width of grid column $gap_w = 35; 
// padding + margin-right (15+15+5) $max_col = 2; 
// max column size (style div.x1 ~ xN) 
// * additional info * 
// check also "style.css" and "header.php" if you change $col_w and $gap_w. 
// - style.css: 
// div.x1 ~ xN 
// div.grid-item 
// div.single-item 
// ... and maybe #sidebar2 li.widget. 
// - header.php: 
// gridDefWidth in javascript code. 
// // if you want to show small images in main page always, set $max_col = 1. 
// [grid image link setting] $flg_img_forcelink = true; 
// add/overwrite a link which links to a single post (permalink). $flg_img_extract = false; 
// in single post page, extract thumbnail link to an original image. $flg_obj_fit = 'large-fit'; 
// none | small-fit | large-fit ... how to fit size of object tag. 
// * additional info * 
// if you use image popup utility (like Lightbox) on main index, set $flg_img_forcelink = false; 

我已經測試了兩個主題,他們自己工作。對於Tanzaku模板,我必須禁用我用於現代主義基本主題的front.php。

我檢查了apache日誌,但沒有錯誤。我怎麼能檢查加載的頁面的錯誤,但不會返回我想要的結果?

+2

你真的從服務器獲得所有評論代碼作爲輸出?這意味着你有一個額外的'?>'在某處「關閉」PHP,允許代碼泄漏出去。 –

+0

有沒有簡單的方法來找到這個額外的?> – tokyowp

+0

下載Eclipse Helios for php,它會顯示你是你的缺失標籤。或者你可以用你的眼睛使用舊的方式:) – OldWest

回答

0

拿出額外的「?>」。謝謝Marc B!想要結束這個問題,所以回答了它。

+0

@ Lord Torgamus我需要等20個小時才能點擊複選標記。 – tokyowp