Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.

Javascript check for bookmark options?

I am wanting to add a javascript check in a web page. So when a user attempts to close/leave the web page it will check to see if they have the page bookmarked. If so then it simply allows them to leave. If not it will throw up an alert message informing them they do not have it bookmarked and ask them to do so. THe alert would have two buttons, one will make a bookmark the other will simply allow them to leave without making a bookmark.

Any suggestions or ideas on the best route to do this?

1 Answer

Relevance
  • 10 years ago
    Favorite Answer

    There is no way to do that with JavaScript. JavaScript doesn't have access to bookmarks or favorites.

Still have questions? Get your answers by asking now.