当前位置:网站首页>开区网站打开自动播放音乐的添加跟修改教程
开区网站打开自动播放音乐的添加跟修改教程
2022-07-29 05:06:00 【V13807970340】
1、插入音乐视频的代码
在网页中插入播放声音(如mp3等)、AVI动画和电影文件(如MPG等)的代码:
在代码窗口中的<body>和</body>之间插入以下代码:
<Embed src="url"width="宽度"height="高度"AUTOSTART="TRUE│false" LOOP="TRUE"></Embed>
【注解】
<EMBED…………………起始标记
SRC="url"……………源文件名
width="450"…………播放器的宽度
height="380"…………播放器的高度
HIDDEN="TRUE"………隐藏方式(对播放声音文件有用,对播放视频无用)
AUTOSTART="TRUE"……自动播放
autostart="false"……不自动播放,点击播放按钮后才播放。
LOOP="TRUE"…………循环播放
NAME="MySound"………嵌入对象名
</EMBED>………………结束标记
【例3】打开网页并点击播放器的播放按钮后才播放视频文件kkk.mpg:
<Embed src="kkk.mpg"width="450"height="380" autostart="false" ></Embed>
【技巧】此法对制作课件特别有用,可在网页当前页播放视频动画。但是,打开网页时播放器总在网页的左侧,如何定位播放器的位置呢?其实插入此代码可以在设计视图中利用层来完成,实现方法是:在DW中的设计视图,插入层,鼠标定位于层内,在层内插入代码(按右键\点插入HTML,在弹出的“插入HTML<>”窗口中的括号<>中间输入代码。如果要编辑修改代码,这样做:右击标签\编辑标签。)。通过移动层就可以准确定位播放器的位置了。
【视频格式转换】用超级解霸或会声会影可将VCD中的某个视频文件(.DAT)转换为视频文件(.mpg)。
【例4】打开网页后自动播放(就象背景音乐)声音文件mlh.mp3:
<Embed src="mlh.mp3" HIDDEN="TRUE" AUTOSTART="TRUE"></Embed>
2、插入播放背景音乐(wav、midi、mp3)的代码
只要在代码窗口中的<head>和</head>标签之间以下代码即可:
<bgsound src="Music File Name" loop=n>
【注】①Music File Name是背景音乐文件名,其格式可以是:.mid,.mp3,.wav,.wma,.rmi。
②n表示循环次数,若n为-1则表示无限循环。
③网页文件和音乐文件要在同一文件夹中。
【例5】无限循环播放背景音乐mlh.mp3:
<bgsound src="mlh.mp3" loop="-1">
边栏推荐
- 自贸经济中架起的“隐形桥梁”:国货精品与中国AI力量
- Five correlation analysis, one of the most important skills of data analysts
- pytorch学习笔记
- JS daily question (10)
- How to debug UDP port
- AttributeError: ‘module‘ object has no attribute ‘create_connection‘
- Solution | get the relevant information about the current employees' highest salary in each department |
- Un7.28: common commands of redis client.
- 【微信小程序--解决display:flex最后一行对齐问题。(不连续排列会分到两边)】
- PHP determines whether the user has logged in. If logged in, the home page will be displayed. If not, enter the login page or registration page
猜你喜欢

Data Lake: spark, a distributed open source processing engine

Reveal installation configuration debugging

Implementation of flutter gesture monitoring and Sketchpad

ODOO开发教程之图表

WPS insert hyperlink cannot be opened. What should I do if I prompt "unable to open the specified file"!

1 sentence of code, get asp Net core binds multiple sources to the same class

How to install Office2010 installation package? How to install Office2010 installation package on computer

Learn matlab to draw geographical map, line scatter bubble density map

使用Jstack、Jconsole和jvisualvm进行死锁分析

A little knowledge about management
随机推荐
Sguard64.exe ace guard client exe: frequent disk reading and writing, game jamming, and Solutions
pytorch学习笔记
荣耀2023内推,内推码ambubk
Software test interview questions (4)
[wechat applet -- solve the alignment problem of the last line of display:flex. (discontinuous arrangement will be divided into two sides)]
Using jupyter (I), install jupyter under windows, open the browser, and modify the default opening address
iOS面试准备 - 其他篇
【微信小程序】swiper滑动页面,滑块左右各露出前后的一部分,露出一部分
How to open IE browser by running win command
网安学习-内网安全1
What if the office prompts that the system configuration cannot run?
Word如何查看文档修改痕迹?Word查看文档修改痕迹的方法
Mapper agent development
开源汇智创未来 | 2022开放原子全球开源峰会 openEuler 分论坛圆满召开
Wechat picture identification
def fasterrcnn_ resnet50_ FPN () instance test
How does WPS use smart fill to quickly fill data? WPS method of quickly filling data
Solution to the fourth game of 2022 Hangzhou Electric Multi school league
五个关联分析,领略数据分析师一大重要必会处理技能
How to debug UDP port