0

Is it possible when a user is using the internet on an android device and they go to a specific website they will get redirected to another static webpage by a php script. The IDE I am using is android studio.

user2151530
  • 1
  • 1
  • 1
  • 3

3 Answers3

0

Unless you make your own browser app it is not possible to access default or chrome or any other browser. Though you can make your php link that can do it so. Like... www.customlink.com which redirects to www.customlink2.com or anything, but it is from php side, not from andoid... :)

kiturk3
  • 528
  • 9
  • 29
0

yes you can do that in php.

use the header function in php

Eg: header('Location:http://your_url.com');

Sourabh Kumar Sharma
  • 2,756
  • 3
  • 20
  • 31
0

You don't need any code on the android device. Take a look at this answer here on how to detect a user on a mobile device using php and then simply redirect him to another url.

Community
  • 1
  • 1
Sotiris Kiritsis
  • 2,741
  • 3
  • 18
  • 28