Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
Digital Lifestyle
Web Design and Hosting
Safari and Flash Video
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="vansmith" data-source="post: 1384765" data-attributes="member: 71075"><p>If you're only going to use Flash, you don't need the elaborate case statement to detect the browser - just load the Flash player and move on. However, doing that excludes iOS users since Flash doesn't work there. Thus, the case statement might be of use but only to detect iOS and non-iOS users.</p><p></p><p>This is why you'd be better off encoding videos as H.264 & WebM and write a video tag with multiple source inputs (taken from the w3schools page linked to earlier):[code]<video width="320" height="240" controls="controls"></p><p> <source src="movie.mp4" type="video/mp4" /></p><p> <source src="movie.webm" type="video/webm" /></p><p> Your browser does not support the video tag.</p><p> </video>[/code]In that case, the mp4 version will be served up and if that fails, the WebM version will be served. Between the two, you'll get 99.9% of web users.</p><p></p><p>MPEG-4 will work on OS X - support is built in through QT. I can't explain why it doesn't work for the one user - that's admittedly a mystery to me.</p><p></p><p>As for the code itself, any reason you're using three equal signs? As far as I know, one equal sign is used for assignment and two is used for equality. I could be wrong - I'm a bit of a JS newbie.</p></blockquote><p></p>
[QUOTE="vansmith, post: 1384765, member: 71075"] If you're only going to use Flash, you don't need the elaborate case statement to detect the browser - just load the Flash player and move on. However, doing that excludes iOS users since Flash doesn't work there. Thus, the case statement might be of use but only to detect iOS and non-iOS users. This is why you'd be better off encoding videos as H.264 & WebM and write a video tag with multiple source inputs (taken from the w3schools page linked to earlier):[code]<video width="320" height="240" controls="controls"> <source src="movie.mp4" type="video/mp4" /> <source src="movie.webm" type="video/webm" /> Your browser does not support the video tag. </video>[/code]In that case, the mp4 version will be served up and if that fails, the WebM version will be served. Between the two, you'll get 99.9% of web users. MPEG-4 will work on OS X - support is built in through QT. I can't explain why it doesn't work for the one user - that's admittedly a mystery to me. As for the code itself, any reason you're using three equal signs? As far as I know, one equal sign is used for assignment and two is used for equality. I could be wrong - I'm a bit of a JS newbie. [/QUOTE]
Verification
Name this item 🌈
Post reply
Forums
Digital Lifestyle
Web Design and Hosting
Safari and Flash Video
Top