Today I discovered that I can make a page like a native app with shortcut on the homescreen, opens almost full screen ... I did a test and it worked, now I need to make it work 100% fullscreen, hiding the top bar and down on Android 4.3 and 4.4, is it possible?
https://developers.google.com/chrome/mobile/docs/installtohomescreen
Android 4.3 and 4.4 come with Chrome for Android by default, so Yes.
If you are asking if you can do this with the Stock Android browser which is on non-Google Android phones and phones that have upgraded from an earlier Android version, the answer is no not quite.
Android Browser does allow you to window.scrollTo(0,1) which will hide the navigation bar (but it will be visible if the user scrolls)
Related
I have a requirement where right click in an existing website needs be supported in iPad. By convention, right click is converted to long press event in touch enabled devices. I have tested in Chrome in Android devices and it worked while it's broken in Safari in iPad (iPad Air 2, 10.3). Just for reference, I was using this demo site:
http://wwwendt.de/tech/demo/jquery-contextmenu/demo/
Could this be a bug in Safari in iOS devices?
Hi Im developing an application where firefox needs to be kiosk mode on browser start. I got it working on all platforms except mac 10.10 ?
Im compiling mozilla source with "fullscreen" in browser.xul and rkiosk addon and
Using obective-c code to hide dock and top menubar and then start firefox.. Works like charm in all macs but 10.10. In 10.10 it leaves the dockarea and top menu area uncovered.
Any ideas where i can tweak the mozilla source ?
Where does mozilla calculate height and width when it starts ?
Can I tweak the fullscreen api to allow fullscreen from js code rather than on user click ? document.documentElement.mozRequestFullScreen -- this doesnt work unless a user initiates an event.
In Safari Mobile on iOS <8, all Javascript was paused while the user was scrolling. Since the release of iOS 8, this is no longer the case, as you can read here:
http://developer.telerik.com/featured/scroll-event-change-ios-8-big-deal/
This is great news. Executing Javascript while scrolling (if done right), opens the possibility for many usability enhancements (like sticky menus) and effects (like parallax).
Is there a way to get the same thing in Chrome Mobile on iOS?
The same website states that the first mobile browser that supported live scroll events was Chrome on Android 4.0. If that's the case, why is it still disabled in the newest Chrome on iOS?
This might be the answer:
https://code.google.com/p/chromium/issues/detail?id=423444
If the new Javascript handling is tied to the new Nitro Javascript Engine used in Safari Mobile (and in WKWebView), then we will have continuous scroll events in Chrome Mobile as soon as they switch to use WKWebView instead of UIWebView.
EDIT: As of version 48.0.2564.87, Chrome uses WKWebView on iOS, and continuous scroll events are working!
I have an application which is running on Safari in IPad(IOS 7) . When i click on one of the button it is showing some JS error. Where exactly i need to into for the script error console? I don't see any error console in safari when it is running on IPad.
Get a Mac computer
Open Safari on Mac
Enable the Develop menu https://developer.apple.com/library/mac/documentation/AppleApplications/Conceptual/Safari_Developer_Guide/GettingStarted/GettingStarted.html
Using a cable, connect your iPad to the Mac
On the iPad enable Web Inspector. Settings > Safari > Advanced (scroll down to the bottom to see it) > Web Inspector (set to On)
On the iPad open the Web application
On the Mac open the Develop menu. When it drops down, you will see your iPad shown in the menu as a separate menu item. That menu item should have a submenu showing Web pages/applications currently opened on your iPad. Choose your Web application.
You get your application in the Development Console, so do whatever you can (Safari Development tools are pretty weird, but, still, better something than nothing :) )
Actually you can see the console on Mac's Safari when your iPad is connected to it.
I am seeing problem happen only on iOS 6 but working fine on below iOS 6 version.
My app is loading image from a link which need to enlarge its image pixels to populate within size of UIWebView by using Javascript. The link image is originally in pixels 140x24.
I see it is running over the line, but the image not being scaled up using iOS 6 simulator. It does work in iOS 5 simulator. Please help.
(void)webViewDidFinishLoad:(UIWebView *)webView {
[webView stringByEvaluatingJavaScriptFromString:#"document.getElementsByTagName(\"img\")(0).height=\"30\";document.getElementsByTagName(\"img\")(0).width=\"280\";"];
}
The syntax in javascript to get the n-th element of an array is using square braces, not parentheses. So use document.getElementsByTagName("img")[0] not document.getElementsByTagName("img")(0).
Not sure why it was working in iOS5, WebKit is probably more strict in iOS6…
Additional tip: to debug javascript errors on iOS6, a new feature makes it very simple:
Go to the "Settings" application in your iPhone, enter the "Safari" settings and tap on "Advanced" at the bottom, then enable the "WebKit Inspector" from there
Display your page to be debugged on the screen (i.e. launch your app and go to your screen that contains the WebView to make it visible)
Plug your iPhone to your Mac via your USB cable
Open Safari.app on your Mac, go to the "Development" menu (1), select the menu item with the name of your iPhone and select your application in the submenu.
You will then be able to debug your web page presented in your iPhone using the powerful Web Inspector from your Mac, and can look into the javascript console, the DOM tree, etc.
(1) If you don't have the "Development" menu in Safari on your Mac, you can enable it in the "Advanced" preferences tab of the Safari application.