IntraWeb程序發生錯誤時,會跳出ATOZED公司的頁面,使我們的程序看起來不是那麼專業了。下面是摘自網絡的文章:
How to customize the error screen in Intraweb
In order to have Intraweb display your error page instead of the default one, you must take the following steps:
Create a file named "IWError.html"
Fill it with something like this:
<html>
<head><title>Da error is in da house</title></head>
<body>
<p align="center"><img src="{%ATOZEDLOGO%}">
<p>
<h3>Beware the mighty error!!!</h3>
</body>
</html>
Place IWError.html in the application "Templates" folder.
Use the following placeholders inside, wherever you want them:
{%ATOZEDLOGO%} to display the Atozed logo
{%INTRAWEBLOGO%} to display the Intraweb logo
{%CONTENT%} to display the exception message
{%APPADDRESS%} to display the application address
{%EXCEPTIONSPECIFIC%} to display an exception specific explanation (only a few are defined)
{%APPNAME%} to display the application name
Do not use single quotes
The file IWError.html is output via Javascript. Make sure you don't have single quotes in it, or else you'll end in a Javascript error.
------------------------------------------------------------------------------------------------
怎樣定製intraweb的錯誤頁面。
爲了使intraweb顯示你的錯誤頁面,而不是默認的,你必須安照下面幾個步驟:
創建一個命名爲"IWError.html"的文件
在裏面寫入如下代碼:
<html>
<head><title>Da error is in da house</title></head>
<body>
<p align="center"><img src="{%ATOZEDLOGO%}">
<p>
<h3>Beware the mighty error!!!</h3>
</body>
</html>
把IWError.html放到工程的"Templates"文件夾中.
你可以在任何地方使用下面的佔位符({%%})中的文字(使用時要包括{%%})
{%ATOZEDLOGO%} 顯示Atozed的標誌logo
{%INTRAWEBLOGO%} 顯示Intraweb的標誌logo
{%CONTENT%} 顯示例外消息
{%APPADDRESS%} 顯示應用程序地址(url地址)
{%EXCEPTIONSPECIFIC%} 顯示例外的詳細說明(只有一些被定義)
{%APPNAME%} 顯示應用程序的名稱
不要(在文件中)使用單引號
IWError.html文件是通過Javascript輸出的。請務必確認你的文件中沒有單引號,否則你的頁面會在一個Javascript錯誤中終止(無法輸出)。
--------------------------------------------------------------------
效果圖