網站建設是指使用標識語言(markup language),通過一系列設計、建模、和執行的過程將電子格式的信息通過互聯網傳輸,最終以圖形用戶界面(GUI)的形式被用戶所瀏覽。簡單來說,網頁設計的目的就是產生網站。簡單的信息如文字,圖片(GIF,JPEG,PNG)和表格,都可以通過使超文件標示語言、可擴展超文本標記語言等標示語言放置到網站頁面上。 1,CSS,JS,IMG一個都不能少運行代碼框 <style type="text/css"><!--.trans_img {filter:alpha(opacity=30,enabled=1) blendtrans(duration=1); border:0 solid black}--></style><script language=javascript> function transImg(obj,enable) { obj.filters.blendtrans.Apply(); obj.filters[0].enabled=enable; obj.filters.blendtrans.Play(); }</script><img src="http://www.fixdown.comhttp://www.fixdown.com/article/UploadPic/2006-1/200618112344826.gif" class="trans_img" onmouseover="transImg(this,0)" onmouseout="transImg(this,1)"> [Ctrl+A 全部選擇 提示:你可先修改部分代碼,再按運行]2,JS & IMG運行代碼框 <script language="JavaScript"> nereidFadeObjects = new Object();nereidFadeTimers = new Object();function nereidFade(object, destOp, rate, delta){if (!document.all)return if (object != "[object]"){ file://do this so I can take a string too setTimeout("nereidFade("+object+","+destOp+","+rate+","+delta+")",0); return; } clearTimeout(nereidFadeTimers[object.sourceIndex]); diff = destOp-object.filters.alpha.opacity; direction = 1; if (object.filters.alpha.opacity > destOp){ direction = -1; } delta=Math.min(direction*diff,delta); object.filters.alpha.opacity+=direction*delta; if (object.filters.alpha.opacity != destOp){ nereidFadeObjects[object.sourceIndex]=object; nereidFadeTimers[object.sourceIndex]=setTimeout("nereidFade(nereidFadeObjects["+object.sourceIndex+"],"+destOp+","+rate+","+delta+")",rate); }}</script><a target="_blank"><img border="0" src=http://www.fixdown.comhttp://www.fixdown.com/article/UploadPic/2006-1/200618112344826.gif onMouseOut=nereidFade(this,50,10,5) onMouseOver=nereidFade(this,100,10,5) style="FILTER: alpha(opacity=50) " border=0></a> [Ctrl+A 全部選擇 提示:你可先修改部分代碼,再按運行]3,用htc文件,不用JS從而減輕工作量。 下載alpha.htc: http://www.cnbruce.com/js/alpha.htc
效果頁查看:http://www.cnbruce.com/js/a.html 4,有點Flash的味道,一閃而過。運行代碼框 <SCRIPT language=Javascript type=text/javascript>function trains(id,text){document.all[id].innerHTML=' '+text}function trainpic(id,text){document.all[id].innerHTML='<img src="'+text+'.gif">'}function high(which2){theobject=which2;theobject.filters.alpha.opacity=0highlighting=setInterval("highlightit(theobject)",50)}function low(which2){clearInterval(highlighting)which2.filters.alpha.opacity=100}function highlightit(cur2){if (cur2.filters.alpha.opacity<100)cur2.filters.alpha.opacity+=15else if(window.highting)clearInterval(highlighting)}</SCRIPT><a ><IMG onmouseover="this.style.filter='alpha(opacity=100)';high(this)" onmouseout="low(this)" src="http://www.fixdown.comhttp://www.fixdown.com/article/UploadPic/2006-1/200618112344826.gif" border="0"></a> [Ctrl+A 全部選擇 提示:你可先修改部分代碼,再按運行]5,還有圖片的“黑白轉彩色”運行代碼框 <SCRIPT>function doTrans(filterCode) {imgObj.filters[0].apply();oImg.style.filter = filterCodeimgObj.filters[0].play();}</SCRIPT><SPAN id=imgObj onmouseleave='doTrans("gray")' style="FILTER: progid:DXImageTransform.Microsoft.Fade(Overlap=1.00); WIDTH: 1px" onmouseenter='doTrans("")'><IMG id=oImg style="FILTER: gray" src="http://www.fixdown.comhttp://www.fixdown.com/article/UploadPic/2006-1/200618112344826.gif"> </SPAN> [Ctrl+A 全部選擇 提示:你可先修改部分代碼,再按運行] (出處:藍色理想)大多數人在上網的時候,都會瀏覽網頁提供給我們的信息。
|