无法通过javascript在Android playstore中打开应用程序链接

时间:2017-07-03 11:26:05

标签: javascript html

我希望当我加载html页面时,他会重定向到Playstore应用程序

我在chrome中获得playstore而不是在Android应用程序中的问题

我试过这个没有成功

  

1

<a id="androidLink" href="https://play.google.com/store/apps/details?id=mylink" target="_top"></a>

document.getElementById("androidLink").click();
  

2

window.location.href = "https://play.google.com/store/apps/details?id=mylink";
  

3

header('location: mylink ')
  

4

window.location.href = "market://details?id=mylink";

1 个答案:

答案 0 :(得分:0)

请查看this answer:这是您应该用来在PlayStore应用程序上重定向的链接。