marquee標(biāo)簽屬性詳解 direction 屬性 屬性的參數(shù)值 示例代碼 示例 direction="left" 向左(默認(rèn)值)
<marquee direction="left">我向左滾動(dòng)</marquee>
direction="right" 向右 <marquee direction="right">我向右滾動(dòng)</marquee>direction="up"
<marquee direction="up">我向上滾動(dòng)</marquee>
direction="down" 向下
<marquee direction="down">我向下滾動(dòng)</marquee>
behavior 屬性 屬性的參數(shù)值 示例代碼 示例 behavior="alternate" 來(lái)回滾動(dòng) <marquee behavior="alternate">我來(lái)回滾動(dòng)</marquee>behavior="scroll" 單方向循環(huán)滾動(dòng)
<marquee behavior="scroll">我單方向循環(huán)滾動(dòng)</marquee>
<marquee behavior="scroll" direction="up" height="30">我改單方向向上循環(huán)滾動(dòng)</marquee>
我改單方向向上循環(huán)滾動(dòng) behavior="slide" 只滾動(dòng)一次
<marquee behavior="slide">我只滾動(dòng)一次</marquee>
<marquee behavior="slide" direction="up">我改向上只滾動(dòng)一次了</marquee>
我改向上只滾動(dòng)一次了 loop 屬性 屬性的參數(shù)值 示例代碼 示例 loop="2" 滾動(dòng)2次
<marquee loop="2">我滾動(dòng)2次。</marquee>
loop="infinite" 無(wú)限循環(huán)滾動(dòng)
<marquee loop="infinite">我無(wú)限循環(huán)滾動(dòng)。</marquee>
loop="-1" 無(wú)限循環(huán)滾動(dòng)
<marquee loop="-1">我無(wú)限循環(huán)滾動(dòng)。</marquee>
scrollamount速度屬性 scrolldelay 延時(shí)屬性 屬性的參數(shù)值 示例代碼 示例 scrollamount="100" 速度很快
<marquee scrollamount="100">我速度很快</marquee>
scrollamount="50" 速度慢了些
<marquee scrollamount="50">我慢了些。</marquee>
scrolldelay="30" 小步前進(jìn)
<marquee scrolldelay="30">我小步前進(jìn)。</marquee>
scrolldelay="1000" scrollamount="100" 大步前進(jìn)
<marquee scrolldelay="1000" scrollamount="100">我大步前進(jìn)。</marquee>
bgcolor 屬性 背景顏色 屬性的參數(shù)值 示例代碼 示例
bgcolor屬性文字滾動(dòng)范圍的背景顏色,參數(shù)值是16進(jìn)制(形式:#AABBCC或#AA5566等)或預(yù)定義的顏色名字(如red、yellow、blue等)。
<marquee behavior=="slide" direction="left" bgcolor="yellow">我的背景色是黃色的</marquee>
width height 屬性 屬性的參數(shù)值 示例代碼 示例
width和height屬性的作用決定滾動(dòng)文字在頁(yè)面中的矩形范圍大小。
<marquee width="300" height="30" bgcolor="red">我寬300像素,高30像素。</marquee>
hspace vspace 屬性 屬性的參數(shù)值 示例代碼 示例
hspace和vspace屬性這兩個(gè)屬性決定滾動(dòng)矩形區(qū)域距周?chē)目瞻讌^(qū)域。
<marquee width="300" height="30" vspace="10" hspace="10" bgcolor="red">我矩形邊緣水平和垂直距周?chē)?0像素。</marquee> <marquee width="300" height="30" vspace="50" hspace="50" bgcolor="red">我矩形邊緣水平和垂直距周?chē)?0像素。</marquee>
onmouseover =this.stop() onmouseout =this.start() 屬性 屬性的參數(shù)值 示例代碼 示例 表示當(dāng)鼠標(biāo)移上區(qū)域的時(shí)候滾動(dòng)停止,當(dāng)鼠標(biāo)移開(kāi)的時(shí)候又繼續(xù)滾動(dòng)。
<marquee onmouseover=this.stop() onmouseout=this.start()>表示當(dāng)鼠標(biāo)移上區(qū)域的時(shí)候滾動(dòng)停止,當(dāng)鼠標(biāo)移開(kāi)的時(shí)候又繼續(xù)滾動(dòng)。</marquee>
valign align 對(duì)齊屬性 這里是輸入文字 這里是輸入文字 這里是輸入文字 valign 表示元素的垂直對(duì)齊方式,值可以是top,middle,bottom,默認(rèn)為middle。這個(gè)屬性在TABLE標(biāo)簽的表格處理文字。<MARQUEE scrollAmount=3 behavior=alternate> <TABLE borderColor=#003333 align=center border=1> </MARQUEE> <marquee direction=up width="300" height="200" bgcolor=#ccffff><P align=center>這個(gè)屬性決定滾動(dòng)文字位于距形內(nèi)邊框的上下左右位置。</P></marquee> |
|
來(lái)自: 昵稱(chēng)27831725 > 《JSP》