I have a web site and I'd like user add it to favorites by using browser "Add to favorites" feature. However, my link looks like this " I only want user add " to favorites automatically once they choose "add to favorites".
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
<a href="javascript:window.external.AddFavorite('[URL unfurl="true"]http://mypage.com','My[/URL] Page')">Bookmark</a>
<script language=javascript>
function addBookmark() {
var thisPage = String(document.location);
thisPage = thisPage.split("?");
alert(thisPage[0]);
window.external.AddFavorite(thisPage[0],'My Page')
}
</script>
<form name=blahForm>
<a href="javascript:addBookmark()">Bookmark</a><br>
<input type=text name=blahText><br>
<input type=submit value='submit me'>
</form>