0

I have a godaddy domain which I have redirected to my app url but when I enter the godaddy domain on my phone, it opens a web page which doesn't redirect to google play store app.

Forwarding to https 301 Redirect Permanent (Update my nameservers and DNS settings to support this change. (Recommended)

What should I do so that when I enter my godaddy domain, it opens my app in play store?

Klors
  • 2,665
  • 2
  • 25
  • 42
Ayz Ali
  • 41
  • 1
  • 6

2 Answers2

2

use this script on your web page which detect mobile and transfer to play store ,itune store or windows store

<script type="text/javascript" language="javascript">

    var isMobile = {
        Android: function () {
            return /Android/i.test(navigator.userAgent);
        },
        BlackBerry: function () {
            return /BlackBerry/i.test(navigator.userAgent);
        },
        iOS: function () {
            return /iPhone|iPad|iPod/i.test(navigator.userAgent);
        },
        Windows: function () {
            return /IEMobile/i.test(navigator.userAgent);
        },
        any: function () {
            return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Windows());
        }
    };

    if (isMobile.Windows()) {
        window.location = "Windows App Url";
    }
    else if (isMobile.iOS()) {
        window.location = "itune store url";
    }
    else if (isMobile.Android()) {
        window.location = "play store url";
    }

</script>
Ashish Agrawal
  • 1,977
  • 2
  • 18
  • 32
  • hey thanks for the answer, do i need hosting too, to use script i don't have hosting i just have a domain – Ayz Ali Oct 21 '15 at 12:45
0

On the index page of your website, just type in the following code:

<html>
<head>
<meta http-equiv="refresh" content="0; url=<URL_TO_PLAY_STORE>" />
</head>
</html>

Now, whenever anyone will open your website, he/she will be redirected to URL_TO_PLAY_STORE.

Reference: Redirect from an HTML page

Community
  • 1
  • 1
Pramod Ravikant
  • 1,039
  • 2
  • 11
  • 28
  • i don't have hosting , i just have a domain, do i need hosting too, to do this? – Ayz Ali Oct 21 '15 at 12:42
  • Yes, a domain is just a name. You will also require a hosting for this. Buy the cheapest and you can use it for future projects too. – Pramod Ravikant Oct 21 '15 at 12:43
  • Did you wait for 24 hours after you did the 301 redirect? – Pramod Ravikant Oct 21 '15 at 12:45
  • no i didn't wait for 24 hours, but it's opening web page of my app – Ayz Ali Oct 21 '15 at 12:46
  • I will suggest you to wait for 24 hours. If still the problem persist, call GoDaddy customer care after 24 hours. They are very helpful. If they say it can't be done. Buy a hosting and use the code I gave. That will definitely solve your problem. – Pramod Ravikant Oct 21 '15 at 12:47