posts - 262,  comments - 221,  trackbacks - 0

          資料來源:www.w3cschools.com

          一、HTML中的實體(又譯轉義字符):
          A character entity has three parts: an ampersand (&), an entity name or a # and an entity number, and finally a semicolon (;).

          備注:一個HTML實體由三部分構成:&符號、實體名或者一個#加實體編碼、分號

          To display a less than sign in an HTML document we must write: &lt; or <

          The advantage of using a name instead of a number is that a name is easier to remember. The disadvantage is that not all browsers support the newest entity names, while the support for entity numbers is very good in almost all browsers.

          備注:HTML實體是大小寫敏感的

          二、HTML中顯示多個空白字符:
          Normally HTML will truncate spaces in your text. If you write 10 spaces in your text HTML will remove 9 of them. To add spaces to your text, use the &nbsp; character entity.

          三、HTML中的常用實體: 

          Result

          Description

          Entity Name

          Entity Number

          non-breaking space

          &nbsp;

           

          less than

          &lt;

          <

          greater than

          &gt;

          >

          &

          ampersand

          &amp;

          &

          "

          quotation mark

          &quot;

          "

          '

          apostrophe 

          &apos; (does not work in IE)

          '



          -------------------------------------------------------------
          生活就像打牌,不是要抓一手好牌,而是要盡力打好一手爛牌。
          posted on 2008-06-02 22:11 Paul Lin 閱讀(421) 評論(0)  編輯  收藏 所屬分類: Web基礎
          <2008年6月>
          25262728293031
          1234567
          891011121314
          15161718192021
          22232425262728
          293012345

          常用鏈接

          留言簿(21)

          隨筆分類

          隨筆檔案

          BlogJava熱點博客

          好友博客

          搜索

          •  

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 长沙县| 大埔县| 永德县| 赤城县| 林甸县| 姚安县| 鲜城| 双城市| 隆回县| 类乌齐县| 中阳县| 休宁县| 沛县| 曲沃县| 屯留县| 平利县| 周口市| 辉南县| 若羌县| 凭祥市| 浙江省| 韩城市| 会东县| 阜南县| 吉木乃县| 柳江县| 泰兴市| 马山县| 博乐市| 黄浦区| 鄯善县| 呼伦贝尔市| 门源| 伊春市| 镇平县| 绥宁县| 京山县| 丽江市| 铜川市| 安乡县| 夏邑县|