2011-10-15 30 views
5

我在Mac OSX/XAMPP上安裝了XDebug,並且在phpinfo()中正確顯示。但錯誤不是xdebug以前的格式(這些橙色框看起來非常清晰)。XDebug沒有格式化錯誤

某些值是否設置正確(中出現的phpinfo()):

  • 的display_errors:在
  • html_errors:在
  • xdebug.auto_trace:在

如果我切換了XDebug .show_exception_trace到On我看到XDebug添加的新信息正確格式化...這只是基本的錯誤顯示,其外觀沒有改變。然後我假設XDebug被正確啓動並運行。

編輯1:這是我的phpinfo enter image description here

EDIT 2的XDebug的部分:我有一個新的清新干淨的安裝哪裏這個問題已經不occure。

回答

4

xdebug.default_enable負責改善正常錯誤顯示 - 它在您的情況下被激活,所以它應該工作。

爲了測試它是否真的有效,創建一個新的PHP腳本

trigger_error('foo'); 

,看看是否可行。如果是這樣,那麼你的應用程序可能會改變設置。


btw,auto_trace不會改變這個問題。

+2

是不是更多的評論? –

+0

trigger_error顯示一些正確的格式化數據。 – AsTeR

2

我注意到你說

誤差不用於

沒有內容是格式化的方式Xdebug的格式化..

我有一個格式問題:我的網頁的CSS是nude的xdebug顯示!
因此,很多白色的白色產生奇怪的格式。

我加了一些規則[Firefox配置文件] /chrome/userContent.css

.xdebug-error { 
    color: black; 
    font-size: 14px; 
} 
.xdebug-error tr:first-child th { 
    padding: 20px !important; 
} 
.xdebug-error tr:first-child th span { 
    background: transparent !important; 
    color: red !important; 
    display: block !important; 
    float: left !important; 
    font-size: 50px !important; 
    padding-right: 20px !important; 
} 
.xdebug-error tr:first-child th a { 
    color: #fff !important; 
} 
.xdebug-error a { 
    text-decoration: none; 
} 
.xdebug-error a:hover { 
    text-decoration: underline; 
} 
.xdebug-error td { 
    padding: 5px; 
} 

其中大部分作品;不知道爲什麼:第一胎兒標籤失敗<聳聳肩>

祝你好運!蒂姆

+0

在生成的HTML中沒有提及xdebug(因此這不是風格問題。我有標準的php錯誤呈現。 – AsTeR