'php open link with image in the same window
I am opening a link with an image, but I want to ensure that the link always opens in the same page, here is my code
echo "<a href=\"/mysite.com/$directory/$dir/$line\"><img src=\"/mysite.com/images/000001.png\" /></a>";
This works fine, but sometimes opens in a new page, i tried including target = "_self" but cannot get this to work
The link is sent in an email, so in some accounts, a pop window asks if the user wants to open or save, it is this I want to avoid and have the link open directly from the email which it does in gmail but not in hotmail
Solution 1:[1]
Unfortunately, this is not something you can control. The HTML in the email is interpreted by the various email clients and they decide how links should be opened.
The Outlook Web App (used by Hotmail), automatically strips the target attribute on anchor elements and includes target="_blank" instead.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Jacob Mulquin |
