mobile-safari

cannot play iPad <audio> over https

可紊 提交于 2019-12-11 00:49:02
问题 I am trying to play HTML5 on iPad Safari . Below is my code; var audio = document.createElement('audio'); audio.type = "audio/mpeg"; audio.src = audioUrl; x.appendChild(audio); audio.load(); audio.play(); Now my audio files are called over https and for some reasons, it cannot play audio over https...I mean if I try manually playing mp3 files on http, it plays them fine.. How do I fix this issue? 回答1: var audio = document.createElement('audio'); audio.type = "audio/mp3"; audio.src = audioUrl;

AngularJS / How to prevent IE triggering automatically inputs validation?

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-10 23:57:34
问题 I have some page with some forms. Each form contains some constraints on fields, like required and more. I want to display errors on validation only when user interacts with them (UX? => yes). Indeed, as long as the field is $pristine meaning no touched, no errors should be displayed. I managed to achieve this requirement with a lot of browsers, except... Internet Explorer (especially IE > 10). Indeed, IE seems to consider all fields as $dirty from the beginning! Surfing on the web, I found

Mjpeg broken on recent Mobile Safari?

╄→гoц情女王★ 提交于 2019-12-10 23:56:54
问题 I am playing with live mjpeg streams from IP cameras and found that support for mjpeg seems to be broken on recent Mobile Safari releases. I am using a simple HTML test page with an embedded image as follows: <img src="http://[ip_address]/[path]"> This works fine on an iPhone 4S with iOS 5.1, but doesn't show anything on an iPad with iOS 7.0.3. Can someone confirm this? Any known workarounds? 回答1: MJPEG support on iPhone (and on OSX also) has been often broken in the past, and I can confirm

Rails 3.2 app on Heroku with Devise: Can't log in with Mobile Safari

那年仲夏 提交于 2019-12-10 22:46:00
问题 I've built an simple rails app and am deploying it to heroku. The app uses devise for authentication. Everything works fine in development and production environment, ACCEPT when one tries to log in via the Mobile Safari browser on iOS. Heroku logs say the following: 2012-10-17T18:56:52+00:00 app[web.1]: Started POST "/users/sign_in" for 87.123.175.106 at 2012-10-17 20:56:52 +0200 2012-10-17T18:56:52+00:00 app[web.1]: Processing by Devise::SessionsController#create as HTML 2012-10-17T18:56:52

Is is possible to change page zoom in Mobile Safari via Javascript?

半世苍凉 提交于 2019-12-10 21:43:17
问题 I have a site using jquerymobile. It loads an initial webpage, and then as other pages are clicked, they are loaded in an "overlay" which slides over the top. Just like this: http://jquerymobile.com/demos/1.0a4/ ..except mine has pinch zoom enabled. I want the zoom state to be independent on each page the user sees. So, if a user starts on page one, opens an "overlay", zooms in, and then closes the "overlay" -- I want the first page to reset to the original zoom level. Is this possible? 回答1:

Anchors losing click ability after scroll on iOS Safari

一世执手 提交于 2019-12-10 21:31:28
问题 Using this to pick up clicks: $("nav li a").click(function(event) { event.preventDefault(); target = $(this).attr("href").replace('#', ''); goToByScroll(target); }); And this is the scroll function: function goToByScroll(id) { $('html, body').animate({ scrollTop: $("#"+id).offset().top - totalHeight }, 'slow'); } The first click works but after that the links aren't clickable/active unless the page is manually scrolled. Any ideas? 回答1: Under further investigation with an iOS man, we have

Mobile Javascript : prevent “touchend” handler if the user stop the scrolling with a tap

佐手、 提交于 2019-12-10 20:57:41
问题 I'm facing an issue in mobile JS development : (I'm speaking about my issue in iOS while I can't fix my problem, then I'll worry about Android ...) I have a list of elements (of the iMessage app style, like a TableView in xCode) that is scrollable, I added an touchend EventListener to that list to detect when the user want to know more about one element. I differentiate the scroll and the "tap" (because the scroll fire the touchend event too) with these EventListeners applied to the document

How to run local html files on iphone and android mobiles?

时光怂恿深爱的人放手 提交于 2019-12-10 20:55:32
问题 How to run local files on iphone? I use Windows 7 and i have iPhone 4 and android . whenever I need to check on iphone browser I upload files on ftp and open that url in iphone. Is there a way to check local file of my pc on iphone and android without uploading to ftp each time. Like I can see my videos of PC into iphone using Air Server on iphone. I use internet on iphone and android using wi-fi router. I don't want to use Emulators/Simulators I'm talking about checking local files directly

“Safari cannot open the page because the address is invalid” for Google Maps link

青春壹個敷衍的年華 提交于 2019-12-10 20:27:23
问题 I have an iPhone 4s with iOS7 that doesn't have the Google Maps app installed on it. Whenever I try to navigate to a location link on it, it flashes an error at me that says: Cannot Open Page Safari cannot open the page because the address is invalid But then the error goes away (without having to hit OK) and the map shows up, and all subsequent Google Maps links load without this error. When I clear my cache, the error shows up again, but only for the first time, and again disappears on its

iOS Safari selecting multiple options visually for single select

非 Y 不嫁゛ 提交于 2019-12-10 20:12:56
问题 I'm using this "empty optgroup" workaround to get iOS to show option elements with long text in a readable manner. I'm using the following code to test this solution: <p>Choose something:</p> <select> <option>Option A</option> <option>Some other option which is much longer than the first two options that has a distinguising feature at the end: B!</option> <option>Some other option which is much longer than the first two options that has a distinguising feature at the end: C!</option> <option