K
K
Kirill Sidorov2013-04-03 18:03:08
Mobile development
Kirill Sidorov, 2013-04-03 18:03:08

How to position photo selection dialog in Web Application on iPad?

Dear hackers who are developing for mobile systems, tell me what can be done with the photo selection dialog. The page has an input[type=file] with display:none in the styles.
By tapping on an element, I use jQuery to call the click () method on this input. Everything is fine on the desktop, a file selection dialog opens. On the iPhone, too, everything is fine, a dialog appears below with the choice to take a picture or select from the library.
But on the iPad, this is implemented differently, in the form of a popUp window. And due to the fact that the input is hidden, this popup appears wherever it wants, often from above, and when you select the “From Library” item, the dialog simply goes beyond the screen area and it becomes impossible to select a photo. Tell me who knows some kind of hack or a way to deal with this misunderstanding.
I'm afraid I didn't write clearly.here's a screenshot just in case

Answer the question

In order to leave comments, you need to log in

1 answer(s)
T
truekenny, 2013-04-03
@truekenny

Try removing display:none and adding 0.01 opacity before calling click. The input itself can also be positioned.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question