2013-09-24 153 views
0

在Lasso 8.x中,我在LassoAdmin文件夾中創建了一個自定義的error.lasso頁面。我使用的是默認的錯誤頁面模板,加上在頁面的最後一些自定義代碼通過電子郵件發送我的錯誤的副本:Lasso 9自定義錯誤頁面

email_send(
    -to='[email protected]', 
    -from='[email protected]', 
    -subject='[Report] Lasso Error ' + response_filepath, 
    -html=$__html_reply__ 
); 

在套索9,我可以爲每個在LassoGuide指令的自定義錯誤頁.COM

http://lassoguide.com/language/error-handling.html?#error-reporting

To define a custom error page, create a file named 「error.lasso」 and place it in the root of the Web serving folder. Each host that has a distinct web serving folder can have a custom error page.

Custom error pages can be further fine-tuned by placing the 「error.lasso」 file in the web serving folder’s subdirectories. Lasso Server will process the first 「error.lasso」 it encounters on the file path, starting with the current directory and continuing upwards until it reaches the root of the web serving folder. If none are found, Lasso Server will use the default error report.

什麼是套索9相當於$__html_reply__?這是編寫自定義電子郵件模板進行錯誤報告的合理捷徑嗎?

在此先感謝。

回答

0

正如柯簡潔迴應指出,content_body將是最直接的替代品。

關於error_stack的評論很好的提醒了Lasso9錯誤堆棧非常有用,所以如果由於某種原因你不想將它包含在網頁本身中,你一定會希望將它包含在電子郵件中被髮送。