Solution to the failure of autostart false when embedding player embed elements in web pages

高洛峰
Release: 2017-03-07 11:36:51
Original
4218 people have browsed it

Recently, I encountered the need to embed a player in a web page to play sound files at work. Finally, the embed element code was used as follows:

<embed src=&#39;1093.swf&#39; autostart=&#39;false&#39; hidden=&#39;true&#39; loop=&#39;false&#39; ></embed>
Copy after login

Do not let it make a sound when the page is first loaded, so Set the autostart attribute to false. If you want to play it, call the play method of the embed element to play the sound.

It was OK at first, but after a while, I found that the autostart attribute of the embed element was invalid. Set it to false will still play automatically once when the page is loaded. After searching for a long time, I finally found the answer using Google. Adding the following code can solve the problem

<embed id="emswf" src="1093.swf" play="false" flashvars="autoplay=false&play=false" menu="false" hidden="true" loop="false"></embed>
Copy after login

More webpages to embed the player embed element autostart false failure solution For related articles, please pay attention to the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!