Chinaunix首页 | 论坛 | 博客
  • 博客访问: 42230
  • 博文数量: 50
  • 博客积分: 2090
  • 博客等级: 大尉
  • 技术积分: 480
  • 用 户 组: 普通用户
  • 注册时间: 2009-10-04 14:18
文章分类

全部博文(50)

文章存档

2011年(1)

2009年(49)

我的朋友
最近访客

分类:

2009-10-07 18:22:03

  昨天听了上海网务肖飞老师的一节课,主要讲关于html5的新元素,现将自己所学拿出来分享一下。
   自打2000年以来,超文本标记语言第一次添加了新元素,包括新的结构元素包括 asidefiguresection。新的内联元素包括 timemeterprogress。新的内嵌元素有 videoaudio。新的交互元素有 detailsdatagridcommand
   今天首先讲一下结构元素:

由于缺少结构,即使是形式良好的 HTML 页面也比较难以处理。必须分析标题的级别,才能看出各个部分的划分方式。边栏、页脚、页眉、导航条、主内容区和各篇文章都由通用的 div 元素来表示。HTML 5 添加了一些新元素,专门用来标识这些常见的结构:

  • section:这可以是书中的一章或一节,实际上可以是在 HTML 4 中有自己的标题的任何东西
  • header:页面上显示的页眉;与 head 元素不一样
  • footer:页脚;可以显示电子邮件中的签名
  • nav:指向其他页面的一组链接
  • article:blog、杂志、文章汇编等中的一篇文章

我们来考虑一个典型的 blog 主页,它的顶部有页眉,底部有页脚,还有几篇文章、一个导航区和一个边栏,见清单 1。



    Mokka mit Schlag





   
              
     

       

      "/blog/birding/2007/04/23/spring-comes-and-goes-in-sussex-county/">
      Spring Comes (and Goes) in Sussex County


       
       

         

Yesterday I joined the Brooklyn Bird Club for our
          annual trip to Western New Jersey, specifically Hyper
          Humus, a relatively recently discovered hot spot. It
          started out as a nice winter morning when we arrived
          at the site at 7:30 A.M., progressed to Spring around
          10:00 A.M., and reached early summer by 10:15.


       

     



     

       

          "/blog/birding/2007/04/23/but-does-it-count-for-your-life-list/">
           But does it count for your life list?


       
       

         

Seems you can now go           href="
          2007/04/cone_sf">bird watching via the Internet. I
          haven't been able to test it out yet (20 user
          limit apparently) but this is certainly cool.
          Personally, I can't imagine it replacing
          actually being out in the field by any small amount.
          On the other hand, I've always found it quite
          sad to meet senior birders who are no longer able to
          hold binoculars steady or get to the park. I can
          imagine this might be of some interest to them. At
          least one elderly birder did a big year on TV, after
          he could no longer get out so much. This certainly
          tops that.


       

     


     

   
   








下面看一下用html5编写的页面



    Mokka mit Schlag



   

Mokka mit Schlag



              
     

       

        "/blog/birding/2007/04/23/spring-comes-and-goes-in-sussex-county/">
         Spring Comes (and Goes) in Sussex County


       
       

Yesterday I joined the Brooklyn Bird Club for our
        annual trip to Western New Jersey, specifically Hyper
        Humus, a relatively recently discovered hot spot. It
        started out as a nice winter morning when we arrived at
        the site at 7:30 A.M., progressed to Spring around 10:00
        A.M., and reached early summer by 10:15.


     



     

       

          "/blog/birding/2007/04/23/but-does-it-count-for-your-life-list/">
          But does it count for your life list?


       
         

Seems you can now go           href="
          2007/04/cone_sf">bird watching via the Internet. I
          haven't been able to test it out yet (20 user
          limit apparently) but this is certainly cool.
          Personally, I can't imagine it replacing
          actually being out in the field by any small amount.
          On the other hand, I've always found it quite
          sad to meet senior birders who are no longer able to
          hold binoculars steady or get to the park. I can
          imagine this might be of some interest to them. At
          least one elderly birder did a big year on TV, after
          he could no longer get out so much. This certainly
          tops that.


     
   
   




   

Copyright 2007 Elliotte Rusty Harold





很简单的东西,不需要div,也没有必要自己去设置class属性,我们完全可以从元素名推出元素的意义。

阅读(206) | 评论(0) | 转发(0) |
0

上一篇:回忆的那些事

下一篇:HTML 5 参考手册

给主人留下些什么吧!~~