So ihave created a webapp that opens up camera/upload file on user mobile. This has proved work on Ipad and android system. But when it comes to iphone(5c IOS 10.) it does not respond. This is the javascript script that i am using to open the file input dialog
document.getElementById('input').click();
here is Demo
Sample App - Add to Homescreen to test, it works if i click choose file, but seems not to work on click custom button, Please let me know if this does work on your iphone when set to homescreen
Related
My application is developed in ASP.NET
In one of my pages(productinfo.aspx) I have a HTML button named & labelled
as print. I am handling the click of this button in java script like
below.
$('#print').click(function($)
{
window.print();
});
The above is working fine in all browsers on PC and in smartphones as well
except Google Nexus mobiles and tablets. It is working in other android
mobiles like Samsung and Sony experia etc..
I came to know that window.print is not supported in Google android and I
should use Google cloud print based on the following link.
https://developers.google.com/cloud-print/docs/gadget
But this requires the user to be logged into to GCP with their Google ID.
But my requirement is like the device will be not connected to Internet
and it should provide the print as dialog as like in other devices.
Note:
In Android chrome browsers there is a print command in the browsers menu
clicking on that is showing the print dialog without any GCP.
Is it possible to invoke the browsers menu command through java script,
I tired simulating (ctrl+p) key press event on the button click assuming
that it will trigger the browser's print command it too didn't work.
It would be very much helpful if any one can help me with a solution for
this issue.
I am using angularjs and ionic framework for html5 mobile app. The scenario is when user clicks the search box on main page. A modal should load up autofocusing the searchbox input field and cancel button inline. Also when the searchbox in Modal autofocuses on input field, it should also open up the ios keyboard.
Right now what is happening is when I click on searchbox on main page, it opens up the modal with search header and cancel button and also autofocuses on search input field.It is working fine on desktop view. But the autofocus feature is not working properly on ios devices and also the keyboard doesn't pop-up when modal loads up.
Acc. to ionic docs http://ionicframework.com/docs/api/controller/ionicModal/ I am using
focusFirstInput: true
for autofocus to work.
Here is the plunker sample that I created which works fine on desktop but not on iphone 4 and 5.
Please, Let me know how can I make this work on ios and android devices.
Also, as a side question, if anyone knows about a good chrome or safari pluggin to test the application for mobile devices that will be helpful. I know in chrome we can use their emulate feature to test the responsive designs but what pluggin to use if we want to fully test the mobile application.
I'm developing android and ios app with phonegap, so i have a select and i want to open it with js, on ios simply focusing element works nice, but in android it does nothing, simulating click on select also gave no result, maybe there are some plugin for that?
finaly i found a plugin for this issue, you can download it from here
I want to try load a private webpage in uiwebview.
When I try to open it from the native Safari app on my iPhone, everything works well.
But when I try to open in uiwebvie, the buttons on the webpage doesn't work.
Buttons are as follows
<a class="actionButtonWithoutImg" href="javascript:__doPostBack('','')">Edit</a>
Do you have any idea ?
I am developing a iphone app using phoneGap. How can I direct user to safari when he clicks on a link or button inside of the application.
example:
When user taps a button, safari browser will come to front and load corresponding site.
you can use the childbrowser plugin to do that. Take a look here: https://github.com/purplecabbage/phonegap-plugins/tree/master/iPhone/ChildBrowser
This line just worked for me..
location.href="http://www.google.com";