Home >
Computers And Internet >
Javascript
Dirty Web Promotion Tricks #1 - Legitimate and Malicious Javascripts
by Michael Bloch
One of the best way to get visitors to further explore your site is to convince them to set your home page as their Internet start page, or for them to add you their "Favorites". In this article, we'll examine some ethical and unethical ways this is done.
Many sites include legitimate javascripts that allow visitors to easily add a page to their "Favourites" by clicking on a link. A script to achieve this would look like something along the lines of:
=======================================================================
SAMPLE Legitimate "BOOKMARKING" SCRIPT:
//Free for Redistribution. (C) Michael Bloch from WWW.TAMINGTHEBEAST.NET
//Please do not remove these comments. This script can be use within tables.
//Suitable for most 4+ Browsers. Copy and paste into a text editor first,
//change the YOURSITE details to suit, then paste into appropriate area
//between and tags in HTML. Visit Taming the Beast for a
//wide selection of Web development tools and articles!
if ((navigator.appName == "Microsoft Internet Explorer")
&& (parseInt(navigator.appVersion) >= 4))
{
var url="HTTP://WWW.YOURSITE.COM/";
var title="YOURSITE DESCRIPTION (this will appear on bookmark text)";
document.write('
More articles by Michael Bloch:

