Add your web to Bookmark

Written by @kerixa 21 August 2012

This is a sample to show how to put your website in the visitor's bookmark just by clicking.

Code Snippet:

                                                
                                                <!-- this script is provided by https://www.javascriptfreecode.com coded by: Kerixa Inc. -->
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256">
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 6.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title></title>
</head>

<body>

<!-- START OF Add Bookmark in IE DHTML -->

<!-- SUMMARY BRIEF

	This code will allow you to put a link on your
	page that, when clicked, will add a URL to the
	user's Favorites.

	NOTE: This will only work for IE users. It will
	NOT work for users using Netscape.

	You can change the bookmark link and text in the
	var bookmarkurl and var bookmarktitle attributes
	below.

	You can change the text of the actual link in the
	<A HREF> code that you will place for your link
	to appear in your page. It is located at the
	bottom of this page.

-->

<!-- Put this code inside of your <HEAD> tag. -->


<script language="JavaScript1.2">
<!--

var bookmarkurl="http://www.javaScriptfreecode.com/"
var bookmarktitle="-=[ Java Web Site ]=-"

function ccaddbookmark() {
	if (document.all)
	window.external.AddFavorite(bookmarkurl,bookmarktitle)
}

//-->
</script>


<!-- Put this code into your page wherever you want the link to be. -->


<a href="javascript:ccaddbookmark()" target="_self">
<font size="1" face="Arial">[ Add Webloger to your Favorites ]</font>
</a>
<!-- END OF Add Bookmark in IE DHTML -->

<a target='_blank' href='https://www.javascriptfreecode.com' style='font-size: 8pt; text-decoration: none'>JavaScript Best Codes</a>                                                
                                            

Example:


About @kerixa

I am Krishna Eydat. I studied Software Engineering at University of Waterloo in Canada. I lead a few tech companies. I am passionate about the way we are connected. I would like to be part of something big or be the big deal!

K

Comments


Here you can leave us commments. Let us know what you think about this code tutorial!

0 / 300

TRENDING POST
1
2
3
4
5
VISITORS
Online Users: 12
Recent Members: admin_js, bloxio, yqaice, flooketsu, phuang_test
advertisement 2