lichess.org
Donate

Sound effects

hey KC i have another post about this in another thread. Just make the sounds yourself - it will probably make the videos more entertaining as well
I added it to my todolist but it's gonna be tricky, because I can't install safari on Linux so I can't try it.

Maybe someone who knows a bit of CSS and has Safari could help?
I have safari and in web inspector shows that Toggle sound has class unavailable and display: none , so it seems that this is not css problem, rather something in js.
Oh, I see. That's because lichess detected that the browser was not capable of playing ogg/vorbis sound. In that case, the sound button is hidden.

Solution: use an other browser.
Yes, of course, that is one of solutions :). The other one is to use multiple sources and browser will chose one for which has codec for playing. Something like
<source src="samplesound.ogg" type="audio/ogg">
<source src="samplesound.mp3" type="audio/mpeg">
Maybe it's time for Safari to stop being recommended as a browser in the WebSockets error screen.

It's not your fault that Apple hates the open web. It's a shame that web development is being held back by rubbish like this. And this is for a website for which audio is a minor feature, imagine a multimedia-heavy website's problems with the inconsistency of HTML5 implementations.
Unfortunately Apple has tended towards being an arse-clown when it comes to supporting various codecs. I don't know why they choose to do this, maybe it has something to do with the monetisation of quicktime. :S

I'm leaning closer towards @srxa 's approach. Or at least for the meantime, have the audio icon appear in Safari but have hover text say something like "Safari does not support the audio files used on lichess. Use a browser such as Firefox or Google Chrome to make full use of lichess' services."
idk, maybe there's something more cross-OS that even Mac'n'shit supports?

OGG/MP3/etc. files can all be converted to other formats very easy.

If the OGG was lossless though I wouldn't downgrade it to MP3 just because APPLE though, but idk.
When it comes to HTML5 and cross-browser support, sound is not only issue. There is only three sound formats that you can use for web, and that is .mp3, .wav and .ogg. And mp3 is most supported today, and chrome is in fact only browser that support all formats. Safari have no support for ogg, Opera for mp3, Internet explorer for wav (lol) and ogg, and firefox supports mp3 only from version 21. But, for example, Safari is very secure browser which use standardized HTML5, other browsers often use some nonstandardized functions which can affect security. Also, In my opinion, Chrome and Safari are best browsers for HTML5, then Firefox, and IE just sucks :) . But many people today still use IE and it is very hard to make them use something else. Lichess is big site, with so many players online. From my experience, if there is 1000 players in one moment online, that means that there is at least 10000 visitors every day, and at least 100 000 active players in data base (and those players will visit site at least one time monthly.) I know that it is very hard to maintain cross-browser compatibility, and often coder will feel like they was doing sisyphus job, but you must evaluate pros and cons and decide what to do. In my opinion, all big sites must support all major browsers, because customer is always right :) cheers.

This topic has been archived and can no longer be replied to.