Recently I am developing a progressive web app with Accelerated Mobile Pages (AMP). I have to add anchor link with target="_blank"
so that a user click on that link will be redirected to a new window with anchor location.
<a href="External_Url" rel="external" target="_blank">Click</a>
It's working fine on Android browser but target="_blank"
is totally not working on the iOS Safari browser. I know this can be solved with Javascript but here at AMP we can not use any Javascript due to convention.
Are there any suggestions to make the new window work on the iOS Safari browser on AMP html anchor click with target="_blank"
?
NOTE: I have configured "In New Tab" on iPhone Safari Settings too.
I have investigated the the problem and finally found the proper reason behind the problem.
This is basically happening due to mixed content on document. The site is serving through Https where the links are Http. This is the main cause of safari browser preventing target="_blank" not to go new window. The latest safari browser blocking these type of mixed content links due to security issue.
After serving all the contents as Https including the target="_blank" links, it's working well at my end now.