Do the project, the head gave a task, let JS detect whether the phone installed our company's app. If it is mounted, it will be transferred to the installation page if it is not installed.
First, I went to Baidu, found Baidu on the answer is very messy, I try, the result is still not. The method of Baidu on iOS is feasible, the parents can try it on their own
Let's talk about Android now, no nonsense. Code:
document.getElementById (' Openappand '). onclick = function () {
var IFR = document.getElementById ("IFR");
IFR.SRC = "The address of the app you agreed with the Android engineer";
Ifr.onload = function () {
Window.location.href= "Your App";
};
}
The HTML page has a hidden iframe and a link with an ID of Openappand.
Later found that there is a problem in the mobile UC browser, there is the app can be smoothly adjusted, but no words can not enter the download page, because the UC to shoot.
Then the solution is to get two buttons, one is to adjust the app, one is downloaded. I do not know you heroes who have a good way to solve the problem of mobile UC, welcome message.
JS to determine if the Android phone installed an app method