1. 給網頁添加音樂

      2010-12-14

            當網頁中插入音樂時,要根據不同的后綴名,來寫不同的代碼!下面就是多種格式文件的詳細使用代碼。

            注: 
            "音樂文件和地址"——待播放文件的文件名,前面帶上絕對路徑,
      或者本站的相對路徑。

            width_num——指定一個作為寬度的數字;

            height_num——指定一個作為高度的數字;

            1.mid 
           

            loop="true" height=height_num width=width_num>

            2.mp3
           

            src="音樂文件和地址" border="0" pluginspage=

            "http://www.apple.com/quicktime/download/indext.html">

            3.avi
           

            "height_num" type="application/x-mplayer2">

            4.flash
           

            "http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="width_num" height="height_num" play="true" loop="true"

            quality="high" scale="showall" menu="true">

            5.mpg
           

            height="height_num" type="application/x-mplayer2">

            6.mov
           

            src="音樂文件和地址" border="0" pluginspage=

            "http://www.apple.com/quicktime/download/indext.html">

            7.rm
            " height="height_num">
           
           
           
           

            src="音樂文件和地址" type=

            "audio/x-pn-realaudio-plugin" autostart="true" nolabels="0"

            autogotourl="-1">

            8.上面的都是使用播放器的,如果只是想播放背景音樂的話可以使用如下簡單語句:

                

            loop后面是循環的次數,-1代表無限循環。