富文本字段值<div> &#160; </div >Tridion Rich Text Field DWT 輸出爲「?」
輸出<div>? </DIV >
DWT:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
@@[email protected]@
</html>
我錯過了什麼?
感謝
富文本字段值<div> &#160; </div >Tridion Rich Text Field DWT 輸出爲「?」
輸出<div>? </DIV >
DWT:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
@@[email protected]@
</html>
我錯過了什麼?
感謝
我現在不能嘗試,由於缺乏時間,但幾件事情浮現在腦海中:
編輯
在預覽我得到這個:
<div> </div>
出版後,我得到了你一樣:
<div>?</div>
所以我改變了我的出版指標使用「Unicode(UTF-8)」,而不是「系統默認」,現在當我發佈我得到這個:
<div>Â </div>
我再交由Elena的優秀7 clues to deal with encoding,想通了,我在我的web.config中缺少此:
<globalization fileEncoding="UTF-8" requestEncoding="UTF-8" responseEncoding="UTF-8"/>
這仍然沒有做到這一點,它仍然加載這個奇怪的字符在標籤之間。最後一個線索是因爲編碼沒有被應用到擴展名爲「.html」的頁面。我改名頁面模板有一個擴展名爲.aspx,出版,按下F5和魔法,我的div現在顯示:
<div> </div>
EDIT 2如果你想使用.html擴展名,只需添加到您的網頁<頭>:
<meta http-equiv="Content-type" content="text/html;charset=UTF-8">
如果你在51區建議的外表套上網站,可以考慮加入內測,並問這個問題在http://tridion.stackexchange.com – 2013-02-21 22:23:14