欧美成人在线视频_欧美成人一区二区三区_欧美成人午夜无码A片秀色直播_欧美成人无码A片免费一区澳门_欧美成人视频_欧美成人电影
<dfn id="uwhjw"></dfn>

<address id="uwhjw"></address>

<dfn id="uwhjw"></dfn>

  • <pre id="uwhjw"></pre>
  • 合肥網(wǎng)站建設(shè)
    文章閱讀
    網(wǎng)建技巧
    優(yōu)化技巧
    網(wǎng)建問題
    謹(jǐn)宸新聞
    行業(yè)新聞

    首頁 > 合肥網(wǎng)站建設(shè) > 正文

    發(fā)布一個以前學(xué)習(xí)html時候的總結(jié)

    發(fā)布時間:2011/09/11字體:
    摘要:發(fā)布一個以前學(xué)習(xí)html時候的總結(jié),html學(xué)習(xí)總結(jié),放假歸放假,但是任務(wù)還是要完成啊。今天和大家分享一個我以前學(xué)習(xí)html時候的總結(jié),剛學(xué)習(xí)的人估計看的不是很懂,但是多少會有些幫助。
    以下是以前學(xué)習(xí)html時候總結(jié)的一些短語和方法,包括一些html使用技巧,希望大家認(rèn)真閱讀后有所幫助。

    <a href="#"></a>
    <a href="html.exe"></a>
    <a href="mailto:icyzhl@163.com?cc=icyzhl@126.com&subject='你好'&body='你好啊'"></a>
    <a href="#ffff"></a>
    <a name="ffff"></a>
    <a href="javascript:alert('你好')"></a>
    <a href="####"></a>
    <a href="javascript:void(0)"></a>
    <a href="javascript:void(null)"></a>
    <a href="javascript:;"></a>
    <a href="#" onclick="return false"></a>
    <span style="cursor:hand"></span>
    a:link {font-size:12px;color:red;text-decoration:none;font-style:italic}
    a:link {font-size:14px;color:red;font-weight:normal;text-decoration:underline;font-style:normal}
    a:link {font-size:12px;font-family:華文行楷;font-weight:bolder;color:red;text-decoration:overline}
    style="writing-mode:tb-rl"
    style="writing-mode:lr-tb"
    <form>
    <select onchange="document.body.style.background=this.options[this.selectedIndex].value">
    <option value=url(1.jpg)>背景1
    <option value=url(2.jpg)>背景2
    <option value=url(3.jpg)>背景3
    </select></form>
    調(diào)用css
    favicon  
    <link href="" rel="shortcut icon">
    <link href="" rel="bookmark">
    <link href="css文件地址" rel="stylesheet">
    <style type="text/css">
    在此寫css
    </style>
    <span style="css樣式內(nèi)容"></span>
    <style style="text/css">
    @import url("")
    </style>
    text-decoration:none
    text-decoration:overline
    text-decoration:underline
    text-underline-position:above/below(IE專有屬性)
    text-decoration:line-through
    text-transform:uppercase/lowercase/capitalize
    font-size:大小
    font-family:字體
    font-style:normal/italic
    font-weight:normal/bold/bolder/lighter
    line-height:120%
    writing-mode:tb-rl/lr-tb
    text-indent:?px
    綜合   font:樣式 變形 加粗 字號/行高 字體
      example----font:italic bold 12px/120% 華文行楷


                定義           調(diào)用
               
                .css1 {}         class=css1
                #css2 {}         id=css2
                table {}         說明table 中的所有屬性
                table#css1 {}    table中的所有css1都有這個屬性   id=css1
                table.css1 {}    table中的所有css1都有這個屬性   class=css1
                body,table,input {}   table和body和input都有這個屬性       
                table #css1           table中其他標(biāo)簽擁有的屬性   <table>...<span id=css1
                table .css1           table中其他標(biāo)簽擁有的屬性   <table>...<span class=css1


    image:
    vaspace hspace width heigth dynsrc src lowsrc alt

    form :
    input type="text/password/radio/checkbox/sunmit/file/hidden/botton"
    select option
    textarea
    onmouseover="this.focus() onfocus=this.select()"
    onmouseover="this.value=''"

    font:
    i b u strike &lt; &gt; &amp; &quot;&apos; &reg; &copy

    在網(wǎng)頁中加入html代碼只要在代碼前后加入:<xmp>和</xmp>就可以了

    size color

    basefont color:red;...       base href=""      base target="_top"

    table td tr:
    align=center/right/left   leftmargin   topmargin   cursor   oncontentmenu
    ondragstart oncopy oncut onpaste onselectstart bgcolor background
    width heigth id cellpadding cellspacing border

    bgsound:
    loop=-1/infinite   balance   volume   autostart  

    marquee:
    direction:up/down/left/right
    align:center/right/left/right
    behavior:scroll slide alternate
    vspace hspace height width bgcolor
    scrolldelay   scrollamount


    <span title="你好">你好</span>
    <span onmouseout="window.status=''" onmouseover="window.status='你好'" style="cursor:hand"></span>


    favicon      <link href="" rel="shortcut icon">

    oncontextmenu="return false"
    ondraystart="return false"
    onselectstart="return false"
    oncopy="return false"
    onpaste="return false"
    oncut="return false"

    <meta http-equiv="refresh" content="5;url=http://www.baidu.com"
    <meta name="description" content="內(nèi)容"
    <meta name="keywords" conternt="內(nèi)容"
    <meta name="author" content="張虹亮"
    <meta http-equiv="page-enter" content="revealtrans(duration='3';transition='23')"
    <meta http-equiv="page-exit" content="revealtrans(duration='3';transition='23')"
    <meta http-equiv="content-type" content="text/html;charset=gb2312"

    取消表單按下時的虛線
    <input type=radio hidefocus=true name=sex>你好
    <input type=radio name=sex onfocus="this.blur()">你不好

    加入收藏:
    <form>
    <input type="submit" onclick="window.external.addfavorite('http://www.softku.com.cn','軟酷下載')"></form>


    a的全寫:anchor


    <base target="_top">防止點擊鏈接時新窗口都是在頂部打開

    <p><br>比<br><p>多一行


    如何讓網(wǎng)頁中的廣告自動關(guān)閉:
    ---在網(wǎng)頁廣告條的網(wǎng)頁head和/head中加入:
    <script language="javascript">

    function close(){
    setTimeout("self.close()",5000)
    }//本網(wǎng)頁自動在5秒鐘關(guān)閉
    </script>
    或者:
    function close(){
    self.close()
    }
    setinterval("close()",5000)
    </script>

    frameset frame iframe:
    border bordercolor src name rows cols framespacing frameborder

    flash透明:
    <param name="wmode" value="transparent">

    半透明的表格:
    <table cellpadding=0 cellspacing=0 width=200 height=100><tr><td style="background-color:red;filter:alpha(opacity=20)">&nbsp;</td></tr></table>

    陰影表格:
    <div style="filter:shadow(color=red,direction=120);width=200;padding-right:10;padding-bottom:10">
    <table cellpadding=0 cellspacing=0 width=200 height=100 bgcolor=red><tr><td>&nbsp;</td></tr></table></div>

    特色的表單:
    <form>
    <input type="button" value="空的" disabled>
    <input type="text" value="520" readonly>
    <input type="text" size=30 style="border-top:1px dashed red;border-bottom:1px dashed black;border-right:1px dashed blue;border-left:1px dashed orange;"
    </form>

    <embed src="" width height>
    <bgsound src="" loop=-1/infinite autostart=false/true>
    <param name="wmode" value="transparent">

    背景更換效果
    <style type="text/css">
    .css1 {background-image:url("1.jpg")}
    .css2 {background-image:url("2.jpg")}
    </style>
    <table><tr><td onmouseout="this.className='css1'" onmouseover="this.className='css2'">sage</td></tr></table>

    關(guān)閉網(wǎng)頁
    <script language="javascript">
    function closewindow(){
    window.opener=null
    window.close()
    }
    </script>
    調(diào)用:<form><input type="button" onclick="javascript:closewindow()"></form>

    鼠標(biāo)指向時變背景顏色的表格
    <table cellpading=0 cellspacing=1 bgcolor=red width=100 height=20><tr><td onmouseover="this.bgColor='#efefef'" onmouseout="this.bgColor='#333333'" bgcolor="#ffffff"></td></tr></table>

    細(xì)線表格1:
    <table cellpading=0 cellspacing=1 bgcolor=red width=100 height=20><tr><td bgcolor="#fffff"></td></tr></table>

    細(xì)線表格2:
    <table border=1 bordercolor="#000000" width=100 height=20><tr bordercolor="#ffffff"><td></td></tr></table>

    細(xì)線表格3:
    <input type="text" size=12 readonly="readonly">
    <input type="text" size=12 disabled="disabled">

    凹下的立體表格:
    <table width="100" border="1" cellspacing="1" cellpadding="0" bgcolor=red>
    <tr><td bgcolor="#ff3333">&nbsp;&nbsp;</td><td bgcolor="#ff3333">&nbsp;&nbsp;</td></tr>
    <tr><td bgcolor="#ff3333">&nbsp;&nbsp;</td><td bgcolor="#ff3333">&nbsp;&nbsp;</td></tr>
    <tr><td bgcolor="#ff3333">&nbsp;&nbsp;</td><td bgcolor="#ff3333">&nbsp;&nbsp;</td></tr>
    </table>

    凸出的立體表格:
    <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolorlight=#333333 bordercolordark=#efefef>
    <tr><td bgcolor="#FF0000">&nbsp;&nbsp;</td><td bgcolor="#FF0000">&nbsp;&nbsp;</td></tr>
    <tr><td bgcolor="#FF0000">&nbsp;&nbsp;</td><td bgcolor="#FF0000">&nbsp;&nbsp;</td></tr>
    <tr><td bgcolor="#FF0000"">&nbsp;&nbsp;</td><td bgcolor="#FF0000">&nbsp;&nbsp;</td></tr>
    </table>

    有間距的表格:
    <table width="100" border="1" cellspacing="5" cellpadding="0" bgcolor=gray>
    <tr><td bgcolor="#999999">&nbsp;&nbsp;</td></tr>
    </table>

    <link rel="Shortcut Icon" href="favicon.ico"> IE地址欄前換成自己的圖標(biāo)

    <link rel="Bookmark" href="favicon.ico"> 可以在收藏夾中顯示出你的圖標(biāo)

    <input style="ime-mode:disabled"> 關(guān)閉中文輸入法

    防止別人frame你的網(wǎng)頁:
    <script language="javascript">
    if(top.location!=self.location){
    top.location=self.location
    }
    </script>

    1. oncontextmenu="window.event.returnValue=false" 將徹底屏蔽鼠標(biāo)右鍵
    <table border oncontextmenu=return(false)><td>no</table> 可用于Table

    2. <body onselectstart="return false"> 取消選取、防止復(fù)制

    3. onpaste="return false" 不準(zhǔn)粘貼

    4. oncopy="return false;" oncut="return false;" 防止復(fù)制

    5. <link rel="Shortcut Icon" href="favicon.ico"> IE地址欄前換成自己的圖標(biāo)

    6. <link rel="Bookmark" href="favicon.ico"> 可以在收藏夾中顯示出你的圖標(biāo)

    7. <input style="ime-mode:disabled"> 關(guān)閉輸入法

    8. 永遠(yuǎn)都會帶著框架

    <script language="JavaScript"><!--
    if (window == top)top.location.href = "frames.htm"; //frames.htm為框架網(wǎng)頁
    // --></script>

    9. 防止被人frame

    <SCRIPT LANGUAGE=JAVASCRIPT><!--
    if (top.location != self.location)top.location=self.location;
    // --></SCRIPT>

    10. 網(wǎng)頁將不能被另存為

    <noscript><iframe src=*.html></iframe></noscript>

    11. <input type=button value=查看網(wǎng)頁源代碼
    onclick="window.location = 'view-source:'+ 'http://www.webjx.com/'">

    12.刪除時確認(rèn)

    <a href='javascript:if(confirm("確實要刪除嗎?"))location="boos.asp?&areyou=刪除&page=1"'>刪除</a>
    <a href="return confirm("確認(rèn)刪除嗎?")"

    13. 取得控件的絕對位置

    //Javascript
    <script language="Javascript">
    function getIE(e){
    var t=e.offsetTop;
    var l=e.offsetLeft;
    while(e=e.offsetParent){
    t+=e.offsetTop;
    l+=e.offsetLeft;
    }
    alert("top="+t+"/nleft="+l);
    }
    </script>

    //VBScript
    <script language="VBScript"><!--
    function getIE()
    dim t,l,a,b
    set a=document.all.img1
    t=document.all.img1.offsetTop
    l=document.all.img1.offsetLeft
    while a.tagName<>"BODY"
    set a = a.offsetParent
    t=t+a.offsetTop
    l=l+a.offsetLeft
    wend
    msgbox "top="&t&chr(13)&"left="&l,64,"得到控件的位置"
    end function
    --></script>

    14. 光標(biāo)是停在文本框文字的最后

    <script language="javascript">
    function cc()
    {
    var e = event.srcElement;
    var r =e.createTextRange();
    r.moveStart('character',e.value.length);
    r.collapse(true);
    r.select();
    }
    </script>
    <input type=text name=text1 value="123" onfocus="cc()">

    15. 判斷上一頁的來源

    javascript:document.referrer

    16. 最小化、最大化、關(guān)閉窗口

    <object id=hh1 classid="clsid:ADB880A6-D8FF-11CF-9377-00AA003B7A11">
    <param name="Command" value="Minimize"></object>
    <object id=hh2 classid="clsid:ADB880A6-D8FF-11CF-9377-00AA003B7A11">
    <param name="Command" value="Maximize"></object>
    <OBJECT id=hh3 classid="clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11">
    <PARAM NAME="Command" VALUE="Close"></OBJECT>

    <input type=button value=最小化 onclick=hh1.Click()>
    <input type=button value=最大化 onclick=hh2.Click()>
    <input type=button value=關(guān)閉 onclick=hh3.Click()>
    本例適用于IE

    17.屏蔽功能鍵Shift,Alt,Ctrl

    <script>
    function look(){
    if(event.shiftKey)
    alert("禁止按Shift鍵!"); //可以換成ALT CTRL
    }
    document.onkeydown=look;
    </script>

    18. 網(wǎng)頁不會被緩存

    <META HTTP-EQUIV="pragma" CONTENT="no-cache">
    <META HTTP-EQUIV="Cache-Control" CONTENT="no-cache, must-revalidate">
    <META HTTP-EQUIV="expires" CONTENT="Wed, 26 Feb 1997 08:21:57 GMT">
    或者<META HTTP-EQUIV="expires" CONTENT="0">

    19.怎樣讓表單沒有凹凸感?

    <input type=text style="border:1 solid #000000">

    <input type=text style="border-left:none; border-right:none; border-top:none; border-bottom: 1 solid #000000"></textarea>

    20.<div><span>&<layer>的區(qū)別?

    <div>(division)用來定義大段的頁面元素,會產(chǎn)生轉(zhuǎn)行
    <span>用來定義同一行內(nèi)的元素,跟<div>的唯一區(qū)別是不產(chǎn)生轉(zhuǎn)行
    <layer>是ns的標(biāo)記,ie不支持,相當(dāng)于<div>


    21.讓彈出窗口總是在最后面:

    <body onblur="this.focus();">

    22.不要滾動條?

    讓豎條沒有:
    <body style='overflow:scroll;overflow-y:hidden'>
    </body>
    讓橫條沒有:
    <body style='overflow:scroll;overflow-x:hidden'>
    </body>
    兩個都去掉?更簡單了
    <body scroll="no">
    </body>

    23.怎樣去掉圖片鏈接點擊后,圖片周圍的虛線?

    <a href="#" onFocus="this.blur()"><img src="logo.jpg" border=0></a>

    24.電子郵件處理提交表單

    <form name="form1" method="post" action="mailt****@***.com" enctype="text/plain">
    <input type=submit>
    </form>

    25.在打開的子窗口刷新父窗口的代碼里如何寫?

    window.opener.location.reload()

    26.如何設(shè)定打開頁面的大小

    <body onload="top.resizeTo(300,200);">
    打開頁面的位置<body onload="top.moveBy(300,200);">

    27.在頁面中如何加入不是滿鋪的背景圖片,拉動頁面時背景圖不動

    <STYLE>
    body
    {background-image:url(logo.gif); background-repeat:no-repeat;

    background-position:center;background-attachment: fixed}
    </STYLE>

    28. 檢查一段字符串是否全由數(shù)字組成

    <script language="Javascript"><!--
    function checkNum(str){return str.match(\/D\)==null}
    alert(checkNum("1232142141"))
    alert(checkNum("123214214a1"))
    // --></script>

    29. 獲得一個窗口的大小

    document.body.clientWidth; document.body.clientHeight

    30. 怎么判斷是否是字符

    if (/[^/x00-/xff]/g.test(s)) alert("含有漢字");
    else alert("全是字符");

    31.TEXTAREA自適應(yīng)文字行數(shù)的多少

    <textarea rows=1 name=s1 cols=27 onpropertychange="this.style.posHeight=this.scrollHeight">
    </textarea>

    32. 日期減去天數(shù)等于第二個日期

    <script language=Javascript>
    function cc(dd,dadd)
    {
    //可以加上錯誤處理
    var a = new Date(dd)
    a = a.valueOf()
    a = a - dadd * 24 * 60 * 60 * 1000
    a = new Date(a)
    alert(a.getFullYear() + "年" + (a.getMonth() + 1) + "月" + a.getDate() + "日")
    }
    cc("12/23/2002",2)
    </script>

    33. 選擇了哪一個Radio

    <HTML><script language="vbscript">
    function checkme()
    for each ob in radio1
    if ob.checked then window.alert ob.value
    next
    end function
    </script><BODY>
    <INPUT name="radio1" type="radio" value="style" checked>Style
    <INPUT name="radio1" type="radio" value="barcode">Barcode
    <INPUT type="button" value="check" onclick="checkme()">
    </BODY></HTML>

    34.腳本永不出錯

    <SCRIPT LANGUAGE="JavaScript">
    <!-- Hide
    function killErrors() {
    return true;
    }
    window.onerror = killErrors;
    // -->
    </SCRIPT>

    35.ENTER鍵可以讓光標(biāo)移到下一個輸入框

    <input onkeydown="if(event.keyCode==13)event.keyCode=9">
    本文標(biāo)題:發(fā)布一個以前學(xué)習(xí)html時候的總結(jié)
    本文網(wǎng)址:http://m.xjjhbl.com/wangjianjiqiao/409.html
    原創(chuàng)網(wǎng)址:合肥網(wǎng)絡(luò)公司<謹(jǐn)宸科技> 版權(quán)所有,轉(zhuǎn)載請注明出處,并以鏈接形式鏈接網(wǎng)址:m.xjjhbl.com
    文章標(biāo)簽:html總結(jié)學(xué)習(xí)以前
     上一篇:如何申請好域名?
     下一篇:win8時代即將來臨
    缙云县| 天全县| 广宗县| 禄丰县| 贞丰县| 汽车| 广安市| 勃利县| 阜城县| 偃师市| 昭平县| 扶风县| 兴仁县| 南安市| 宜黄县| 奈曼旗| 旺苍县| 平顶山市| 原阳县| 承德市| 甘肃省| 泌阳县| 砚山县| 海阳市| 交城县| 望奎县| 樟树市| 广灵县| 辛集市| 洱源县| 房山区| 鱼台县| 德令哈市| 威信县| 金湖县| 彰武县| 鸡东县| 临城县| 阿坝县| 兴安县| 屯门区|