Software Archive
Read-only legacy content

Pop Up (Alert) - IPHONE

Rodrigo_Bastos
Beginner
366 Views

Olá, estou com a seguinte dúvida.

No app que desenvolvi, geramos alguns avisos em forma de pop up/alerts. O Alert funciona ok, mas no Iphone ele aparece a informação index.html no "cabeçalho". Como posso resolver esse problema??

Agradeço desde já.

Segue imagens do erro.

0 Kudos
4 Replies
Diego_Calp
Valued Contributor I
366 Views

Hi,

This is the JavaScript alert system object, you can't change it.

Depending on the framework you are using, they may have its own alerts. For example, in App Framework:

$.afui.popup('Your message');

More info here:

https://app-framework-software.intel.com/api.php#$_afui_popup

Regards,

Diego

0 Kudos
Rodrigo_Bastos
Beginner
366 Views

Diego, thanks for the support. I'll try to change my javascript.

Regards.

Rodrigo

 

 

0 Kudos
PaulF_IntelCorp
Employee
367 Views

Hello, I have the following question.

In the app develops, we generate some warnings in the form of pop up / alerts. Alert works ok, but it appears the iPhone index.html information in the "header". How can I solve this problem ??

Thanks in advance.

The following bug pictures.

Rodrigo -- you can use the Cordova core plugin called "notifications" which allows you to create a custom alert that uses native formatting. See the docs here > https://www.npmjs.com/package/cordova-plugin-dialogs. BTW, be careful with the builtin alert mechanism, especially on iOS, it can interfere with some operations and cause what appears to be a freeze of your app because the builtin alert is a blocking operation. For example, if you use an alert alongside the barcode plugin this can happen, because of a conflict between multiple views that cause the alert to be hidden, but an "Okay" is required to release the alert, which is blocking the UI. Also, there are lots of toaster JavaScript libraries out there that provide useful and customizable notifications.

0 Kudos
Rodrigo_Bastos
Beginner
367 Views

Paul, thank you very much for the tip.

Regards

 

0 Kudos
Reply