iFrame in mobile app - upload a file

Hello,


We have an iframe in one of the screens on a mobile app. 


In the site loaded in the iframe, there's an input widget of type file to upload files. 

When we click on that input we only the choice to upload files from Camera or Recorder but with we access the same site via browser we are able to upload files from the file system.


Does anyone know why the difference? And how can we allow uploading files via iframe?


In the scenario we have, upload file from the system is crucial for the functionality to work.


Thanks!

Patrícia Ferreira

Hi Patricia,

Is it an OutSystems page you load in the iframe or another website?

If it is OutSystems, than use the OutSystems features to handle the upload.

If it is not OutSystems, the webpage that you load in the iframe should have the logic to upload.

Regards,

Daniel

Hi Daniël,

Thanks for your reply!


The page that we are loading in the iframe isn't Outsystems.


I don't believe that the problems lies with that page since if we access it from a device browser we can upload the files from the file system, only on the iframe we have on our Outsystems app we can't do it.

Hi,

My point is, if you load a third party (not OutSystems) page in an Iframe, you cannot control what happens on that page. That should be coded on that page.

Regards,

Daniel

Hi,


But does that explains the different behavior between uploading a file using the device browser or uploading a file on the mobile app via an iframe?


I understand what you mean if we would access the site via the browser and have the same behavior as the iframe, but they differ which leads me to a limitation either from iframe, Cordova or Outsystems.


Thank you!

Patrícia

Hi Patricia,

The Iframe in OutSystems is just an HTML5 Iframe, so there are no OutSystems or Cordova specifics I can think of.

When you say browser, you mean the browser on the mobile device running the OutSystems mobile application?

Where does the external page upload too?

Regards,

Daniel