HTML5 Audio Tag in Safari - html

I have a question about the tag in Safari. I have a page with many audio players on it and have set preload="none" so that page loads faster. In all other browsers, there is no text inside the player, but Safari (5.1.7, Mac) shows the text "Loading..." in the player. I personally don't mind it, but I know it will confuse users who think they should be waiting for something to download and may never click the play button.
Is there a way to set that text to something else, or even better, hide it completely?
Any help is appreciated!
Thanks,
Brett

As far as I know, this is something that Safari does by default and can't be changed. However, you could use some sort of jQuery HTML5 player and add a function to display the "loading" text only when the audio is buffering.

Related

How can I autoplay music on my website when someone opens my webpage

How can I set up my website so that music begins playing automatically when a visitor opens the webpage?
I have used autoplay tag on my html but at first it worked but now its not working...
You don't. This is intrusive and considered bad practice. Browers like Chrome and Firefox took steps so it doesn't happens. You could try to find a work around (it used to be iframes but it has since been patched ) but it might hurt your SEO since this is considered bad practice.
If I visit a website and music autoplays I close the tab down and don't come back. It's bad design, please reconsider.
Have the sound muted by default and visual clues for your visitors to start playing.
Edit : Just in case I didn't make it clear. The sound not playing is not a code issue. It's the browser blocking the autoplay.

Prevent autoplay of <video> elements

does someone know how to prevent Chrome and Safari from autoplaying videos? I am looking for an attribute or style I can incorporate into our website, not a browser extension! We have a few videos on the same page and in Chrome they just all start auto playing for some users while in Safari they kind of autoplay, but they don't start at the same time. They all have sound, so I had expected none of them to autoplay, but apparently that is not the case (at least not for all users).
Thanks!
Use autostart=0 and autostart=1
HTML embed autoplay="false", but still plays automatically
https://support.google.com/chrome/forum/AAAAP1KN0B0LkA8FoBoleU/?hl=en&gpf=%23!topic%2Fchrome%2FLkA8FoBoleU
Make sure you use the video or audio HTML5 elements, and NOT object or embed. I also had this problem using the latter HTML elements and the ONLY way to stop them from autoplaying was to change the browser settings. The reason is, because object and embed use a 3rd party plugin or player when playing your media, while video and audio are native to the browser.
If you want to stop them from playing anyway on just your box, below are the settings for Firefox:
Open up your Firefox Browser, click the menu button, and select "Options"
Select the "Privacy & Security" panel and scroll down to the "Permissions" section
Find "Autoplay" and click the "Settings" button. In the dropdown change it to block audio and video. The default is just
audio.

HTML5 - How can I play an audio file multiple times (replay) on a mobile browser?

So I was recently trying to learn html5 stuff and got to the audio tag. It seems to work just fine on my PC's browser, Chrome, but not so much on my android (4.0, using both the stock browser and dolphin). It will play the audio once, but never again. Take this site for example:
http://www.stefanvignir.de/rimshot/
Very basic, it has a button that plays audio every time you press it, but not on my android. It only plays the first time you press it. How do you get around this? Just wait for mobile browsers to update?
I heard a workaround is to set audio.currentTime = 0; but that didn't seem to solve anything.
Apparently you can reset the source (audio.src = audio.src) and that will allow you to play it more than once, but it has to re-download the file. A workaround, I guess, but not acceptable.
Any suggestions? Thanks.
this works in desktop and andriod browsers for multiple presses - and you can wrap in a div etc for styling:
<a onclick="this.firstChild.play()"><audio src="1.mp3"></audio>play</a>
More than just the audio tag so you have more control over what the play button looks like. If you need more buttons you can change the code for pause etc

MP3 Audio tag in Gecko-based (Firefox/Cometbird) browsers

I've been trying to work on a project to he able to turn loop on and off for the MP3 playing on a we page. I was using <embed> and tried changing the loop= property using a javascript getElementByID, but while the image swap would work, the song would still stay on the mode it was on at page load.
Someone else used the idea to use the <audio> tag, and made a togglefor loop=, and said it worked. I tried, and would not work. I went and tried on an example site, and it worked for OGG, but not MP3.
I researched it, and the only thing I could find was that Firefox didn't originally support MP3s due to LAME copyrights/patents, but started supporting the MP3 format in version 9.
What's even stranger, is that sometimes the player controls show up, sometimes they don't. I have random other information show up on the page on load, so can't say if it's random when it shows up, or related: but even when the controls load, the play button never works, and it doesn't start on autoplay. However, in Chrome, it loads up fine.
So to condense, when in IE, it loads the text to say it's not compatible with my browser, meaning I can have an <embed> for if it doesn't work: I just tried it.
Firefox, on the other hand, acts like it WILL load it, and doesn't show the alt text.
I read about some people having trouble with OGGs, talking about a MAME type, but I don't really know anything about that stuff, yet...
I'd really like some ideas on what to do about this, because it doesn't ever even show the text to say it's not supported, it's like nothing's there in FF/CB, and MP3s SHOULD be supported for the past 4 full versions, which I'm assuming is why it doesn't say it's not supported.
Firefox doesn't support MP3 in <audio>, precisely because it's still patented... I have no idea what made you think it's supported in Firefox 9.

Use of <bgsound> tag in HTML

What is the use of the <bgsound> tag in HTML?
It is a non-standard tag which instructs the browser to load and play a sound file (famously, at least in the mid-90's, a MIDI file) while the user is browsing your site.
Except in a few very special cases, the real purpose is to time how fast the user can find his browser's "close" or "back" button. Seriously, don't use it, on almost every site sound is unwelcome.
If you do decide to use it, you'll want to consider marquee and blink as well. Also an animated-GIF construction worker "under construction" sign and purple text on a dark green background.
If you want to give the user an option of playing music on your site (e.g., because its a music site), I suggest that a flash widget is your best bet. Depending on the site, it may or may not be appropriate to auto-play the music. Alternatively, you could use the new HTML5 audio element (though support is lacking).
update: As pointed out by Adam Brown, HTML5 audio is now supported almost everywhere and should be used instead of Flash.
tells the browser to play a particular sound when the page is loaded.
link:
http://www.htmlcodetutorial.com/sounds/sounds_famsupp_18.html
The other answers are all wrong. This tag is used to get the user to close the page instantly.
A "background sound" is a sound that starts to play automatically when the web page is loaded.
This attribute is used to define what the source of the sound is. Insert the file name and file path if necessary here.
http://www.abiglime.com/webmaster/reference/html/tags/bgsound.htm