webApp install bubble for IOS

Hi, have created a webApp for IOS and am trying to figure out how to trigger a popup bubble that instructs the user hoe to download the webApp to their home screen. I’m having trouble getting the bubble to not show when the app is downloaded and in fullscreen mode. I’ve tried a handful of scripts and techniques found online but nothing is working.

Here is the last code I tried to implement in a js function that runs on page load.

I gave the bubble graphic an ID of bubble in the HYPE inspector and have a jquery.js file installed.

$(hypeDocument).ready(function(){
if(window.navigator.userAgent.indexOf(‘iPhone’) != -1){
if(window.navigator.standalone == true){
$(’#bubble’).hide();}
else {
$(’#bubble’).show();}

});

Thanks!

Ok, I have made a few changes and now it works as its supposed to. I’ll post the result that worked for me incase someone else is trying to figure it out!

Thanks

New code:

$(document).ready(function(){
    if(navigator.userAgent.indexOf('iPhone') != -1){//test for other iOS devices?
        if(window.navigator.standalone == true){
            $('#bubble').hide();
            initialize();
        } else {
            $('#bubble').show();
        }
    } else {
        $('#bubble').hide();
    }
});
1 Like