var expDays = 1095;
var exp = new Date(); 
exp.setTime(exp.getTime() + (expDays*24*60*60*1000));

function When(info){
	// When
	    	var rightNow = new Date()
		var WWHTime = 0;
		WWHTime = GetCookie('WWhenH')
		
		WWHTime = WWHTime * 1

		var lastHereFormatting = new Date(WWHTime);  
	        var intLastVisit = (lastHereFormatting.getYear() * 10000)+(lastHereFormatting.getMonth() * 100) + lastHereFormatting.getDate()
	        var lastHereInDateFormat = "" + lastHereFormatting;  // Gotta use substring functions
	        var dayOfWeek = lastHereInDateFormat.substring(0,3)
	        var dateMonth = lastHereInDateFormat.substring(4,10)
		var hours = "" + lastHereFormatting.getHours()
		var year = lastHereFormatting.getYear()
                if (year < 1000) year+=1900
		var minutes = "" + lastHereFormatting.getMinutes()
		if (minutes.substring(0,1) == minutes){
			minutes = "0" + minutes
		}
	        var WWHText = dayOfWeek + ", " + dateMonth + " " + year + " at " +  hours + ":" + minutes// display
	
		SetCookie ("WWhenH", rightNow.getTime(), exp)

	return WWHText;
}

function getCount() {
var ct = GetCookie('WWHCount')
if (ct == null) {
ct = 0;
}
return ct;
}
function Visited() {
	var WWHCount = GetCookie('WWHCount')
	if (WWHCount == null) {
	  WWHCount = 0;
	}
	else{
		++WWHCount;
	}
	SetCookie ('WWHCount', WWHCount, exp);

}
function Count(info){
	var psj=0;
	// How many times
		var WWHCount = GetCookie('WWHCount')
		if (WWHCount == null) {
			WWHCount = 0;
		}
		else{
			++WWHCount;
		}
		SetCookie ('WWHCount', WWHCount, exp);

}



function set(){
//	VisitorName = prompt("Who are you?", "Nada");
//	SetCookie ('VisitorName', VisitorName, exp);
	SetCookie ('WWHCount', 0, exp);
	SetCookie ('WWhenH', 0, exp);
}

function getCookieVal (offset) {  
	var endstr = document.cookie.indexOf (";", offset);  
	if (endstr == -1)    
		endstr = document.cookie.length;  
		return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name) {  
	var arg = name + "=";  
	var alen = arg.length;  
	var clen = document.cookie.length;  
	var i = 0;  
	while (i < clen) {    
	var j = i + alen;    
	if (document.cookie.substring(i, j) == arg)      
		return getCookieVal (j);    
		i = document.cookie.indexOf(" ", i) + 1;    
		if (i == 0) break;   
	}  
	return null;
}

function SetCookie (name, value) {  
	var argv = SetCookie.arguments;  
	var argc = SetCookie.arguments.length;  
	var expires = (argc > 2) ? argv[2] : null;  
	var path = (argc > 3) ? argv[3] : null;  
	var domain = (argc > 4) ? argv[4] : null;  
	var secure = (argc > 5) ? argv[5] : false;  
	document.cookie = name + "=" + escape (value) + 
	((expires == null) ? "" : ("; expires=" + expires.toGMTString())) + 




	((path == null) ? "" : ("; path=" + path)) +  
	((domain == null) ? "" : ("; domain=" + domain)) +    
	((secure == true) ? "; secure" : "");
}

function DeleteCookie (name) {  
	var exp = new Date();  
	exp.setTime (exp.getTime() - 1);  
	// This cookie is history  
	var cval = GetCookie (name);  
	document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
}

function writeUSU()
{

document.write('<br><P><CENTER><B>')
document.write('<a href="http://shankarling.110mb.com/top10.htm">')
document.write('Top 10 Popular links in this website!!!</a> </P>')

document.write('<br><P><CENTER><B>')
document.write('<a href="http://shankarling.110mb.com/quiz/quiz.php">')
document.write('Test your General Knowledge (Inspired by Who Wants to be Millionaire)</a> </P>')

document.write('<br><P><CENTER><B>')
document.write('<a href="http://shankarling.110mb.com/quiz/clues/clues.php">')
document.write('Crossword Clues and Answers</a> </P><br>')

}
function writeMessage()
{
document.write('<CENTER><B>')
document.write('<a href="http://www.efreeguestbooks.com/mg/')
document.write('guest.pl?44193:10:0">')
document.write('Sign my Guestbook</a>')
document.write('<a href="http://www.efreeguestbooks.com/">')
document.write('<img src="http://www.efreeguestbooks.com/mg/image.gif"')
document.write('alt="FREE GUESTBOOKS" border="0"></a>')
document.write('<a href="http://www.efreeguestbooks.com/mg/multi.pl?44193:10:0">')
document.write('View my Guestbook</a></B></CENTER>')

//document.write('<TABLE BORDER=0><TR><TD WIDTH=468>')
//document.write('<FONT FACE="Verdana, Arial" SIZE="2"><center><b>')
//document.write('<a href="')
//document.write('http://www.geocities.com/vspramod/guest.htm"')
//http://pub.alxnet.com/guestbook?id=2335590
//document.write('target="_blank">')
//document.write('<font size=3>View All Suggestions/Comments Posted</font>')
//document.write('</a></center>')

//document.write('<TABLE CELLSPACING=1 CELLPADDING=1 BORDER=0>')
//document.write('<FORM ACTION="http://pub.alxnet.com/guestbook" target="new"')
//document.write('METHOD="POST" NAME="form">')
//document.write('<INPUT TYPE="hidden" NAME="q" VALUE="submit">')
//document.write('<INPUT NAME="id" TYPE="Hidden" VALUE="2335590">')
//document.write('<TR><TD ALIGN=left>')
//document.write('<FONT FACE="Verdana,Arial" SIZE="1">Name:<BR>')
//document.write('<INPUT NAME="name" TYPE=Text SIZE="30"')
//document.write('MAXLENGTH="255"></FONT></TD>')
//document.write('<TD ALIGN=left width=*>')
//document.write('<FONT FACE="Verdana,Arial" SIZE="1">')
//document.write('Homepage address:<BR><INPUT NAME="homepage_url" ')
//document.write('TYPE=Text SIZE="30"')
//document.write('MAXLENGTH="255"value="http://"></FONT>')
//document.write('</TD></TR><TR><TD COLSPAN=2>')
//document.write('<FONT FACE="Verdana,Arial" SIZE="1">')
//document.write('Your Comments:<BR>')
//document.write('<TEXTAREA NAME="text" ROWS=2 COLS=50 ')
//document.write('WRAP=Virtual></TEXTAREA></FONT>')
//document.write('</TD></TR><TR>')
//document.write('<TD><INPUT TYPE=submit onclick="addtext()" ')
//document.write('NAME="submit"  VALUE="Submit"></TD>')
//document.write('</center></TR></FORM></TABLE>')

//document.write('</td><td>')
//document.write('<APPLET code = "WorldClock.class" ')
//document.write('archive= "http://www.geocities.com/vspramod/wClock.jar"')
//document.write('width = "260" height = "150">')
//document.write('<PARAM name="background_color" value="255,255,255">')
//document.write('<PARAM name="border_clock_color" value="0,0,255">')
//document.write('<PARAM name="digit_clock_color" value="0,0,255">')
//document.write('<PARAM name="cities_text_color" value="0,0,0">')
//document.write('<PARAM name="cities_background_color" value="242,202,134">')
//document.write('</APPLET>')
//document.write('</td>')

//document.write('</tr></TABLE>')
}

function writeTable()
{
document.write('<Table width="100%"><tr>')
document.write('<td>')
document.write("<br><center>")

if (getCount()==0){
Visited()
document.write("Hi there. This is your 1st visit to this page")
When()
}
else if (getCount() > 0) {
Visited()
document.write("Welcome back.")
document.write(" Your last visit was on <b>" + When() + "</b>. ")
document.write("<br>Number of visits to this page: <b>" + getCount() + "</b>") 
}
document.write("</center>")
document.write('</td>')
document.write('</tr></table></CENTER>')


document.write('<TABLE border=0 cellPadding=5 cellSpacing=0 ') 
document.write('class=masthead width="100%" >') 
document.write('<TBODY> <TR bgColor=#cccc99><TD align=center class=nav><DIV>') 

//document.write('<A class=nav ') 
//document.write('href="http://vspramod.5gbfree.com/index.htm">') 
//document.write('Home</a> . ') 

document.write('<A class=nav ') 
document.write('href="http://shankarling.110mb.com/index.htm">') 
document.write('Home</a> . ') 

document.write('<A class=nav ') 
document.write('href="mailto:vspramod@yahoo.com?subject=hi there">') 
document.write('Email</a> . ')

document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/statistics.htm">') 
document.write('Statistics</a> . ')

document.write('<A class=nav ') 
document.write('href="http://shankarling.110mb.com/gallery/photoGallery.php" ')
document.write('>New Photo Gallery</a> . ') 

//document.write('<A class=nav ') 
//document.write('href="http://www.geocities.com/vspramod/Prog/progIndex.htm">') 
//document.write('Programming</a> . ') 

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://shankarling.110mb.com/download/download.htm">') 
document.write('Downloads</a> . ')

document.write('<img alt="New" src="http://shankarling.110mb.com/image/new.gif" />')
document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://shankarling.110mb.com/india/india.htm">') 
document.write('India</a> . ')

document.write('<A class=nav ') 
document.write('href="http://shankarling.110mb.com/infotainment/infotainment.htm">') 
document.write('Infotainment</a> . ')

document.write('<A class=nav ') 
document.write('href="http://shankarling.110mb.com/link/links.htm">') 
document.write('Links</a> . ')


//document.write('<A class=nav ') 
//document.write('href="http://www.geocities.com/vspramod/india/india.htm">') 
//document.write('India</a> . ')

document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/Images/image.htm">') 
document.write('Images</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://shankarling.110mb.com/article/article.htm">')
document.write('Articles</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write
('"http://shankarling.110mb.com/friends/friends.htm">')
document.write('Friends TV Show</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://www.geocities.com/vspramod/timepass/timepass.htm">')
document.write('Take-a-Break</a> ')

document.write('<A class=nav ') 
document.write('href="http://www.efreeguestbooks.com/mg/guest.pl?44193:10:0"') 
document.write('target="_blank"> . GuestBook</a>')

document.write('<BR></DIV></TD></TR></TBODY></TABLE>') 

} 
function writeTable1()
{
document.write('<TABLE border=0 cellPadding=5 cellSpacing=0 ') 
document.write('class=masthead width="100%" >') 
document.write('<TBODY> <TR bgColor=#cccc99><TD align=center class=nav><DIV>') 

document.write('<A class=nav ') 
document.write('href="http://vspramod.5gbfree.com/index.htm">') 
document.write('Home</a> . ') 

document.write('<A class=nav ') 
document.write('href="mailto:vspramod@yahoo.com?subject=hi there">') 
document.write('Email</a> . ')

document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/statistics.htm">') 
document.write('Statistics</a> . ')

document.write('<A class=nav ') 
document.write('href="http://photos.yahoo.com/vspramod" ')
document.write('target="_blank">Photo Gallery</a> . ') 

//document.write('<A class=nav ') 
//document.write('href="http://www.geocities.com/vspramod/Prog/progIndex.htm">') 
//document.write('Programming</a> . ') 

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://www.geocities.com/vspramod/Downloads/download.htm">') 

document.write('Downloads</a> . ')


document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/Quiz/infotainment.htm">') 
document.write('Infotainment</a> . ')

document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/Links/links.htm">') 
document.write('Links</a> . ')

//document.write('<A class=nav ') 
//document.write('href="http://www.geocities.com/vspramod/india/india.htm">') 
//document.write('India</a> . ')

document.write('<A class=nav ') 
document.write('href="http://www.geocities.com/vspramod/Images/image.htm">') 
document.write('Images</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://www.geocities.com/vspramod/Articles/article.htm">')
document.write('Articles</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write
('"http://shankarling.110mb.com/friends/friends.htm">')
document.write('Friends TV Show</a> . ')

document.write('<A class=nav ') 
document.write('href=') 
document.write('"http://www.geocities.com/vspramod/timepass/timepass.htm">')
document.write('Take-a-Break</a> ')

document.write('<A class=nav ') 
document.write('href="http://www.efreeguestbooks.com/mg/guest.pl?44193:10:0"') 
document.write('target="_blank"> . GuestBook</a>')

document.write('</DIV></TD></TR></TBODY></TABLE>') 

}   
      

function writeText()
{
document.write('<table border="1" bgcolor="#CCCCCC" width="160">')
document.write('<tr><td bgcolor="#FFFFCC" align="center">')
document.write('<a class=nav href="http://www.geocities.com/vspramod/top25.htm" target="_blank">')
document.write('<b><font size="+1"  COLOR="#023BE2">TOP 25</font></b></a>')

document.write(' </td></tr>')
document.write('<tr><td><center><a class=nav href="http://www.geocities.com/vspramod/top25.htm">')
document.write('Most popular Links</a></center>')
document.write('</td></tr>')
document.write('<tr><td><center><a class=nav href="http://www.geocities.com/vspramod/webcam.htm"')
document.write('target="_blank">')
document.write('Utah State Webcam</a></center></td></tr>')
document.write('<tr><td bgcolor=#ffffff><center>')
document.write('<a href="http://weather.yahoo.com/forecast/USUT0147_f.html"')
document.write('target="_blank">')
document.write('<img src=')
document.write('"http://www.utahstatesman.com/media')
document.write('/rasterWeatherBugs/84322.gif"')

document.write('alt="Click here for more information"')
document.write('width="108" height="72" border="0"></a></center></td></tr>')
document.write('</table>')

}

function worldclock()
{
document.write('<CENTER>')
document.write('<APPLET code = "WorldClock.class" ')
document.write('archive= "http://www.geocities.com/vspramod/wClock.jar"')
document.write('width = "260" height = "150">')
document.write('<PARAM name="background_color" value="255,255,255">')
document.write('<PARAM name="border_clock_color" value="206,2,2">')
document.write('<PARAM name="digit_clock_color" value="0,0,255">')
document.write('<PARAM name="cities_text_color" value="0,0,0">')
document.write('<PARAM name="cities_background_color" value="242,202,134">')
document.write('</APPLET>')
document.write('</CENTER>')
}


function writeFooter()
{
document.write('<!-- BEGIN inlive CODE -->')
document.write('<center><SCRIPT language="javascript" ')
document.write('src="http://www.addfreestats.com/cgi-bin/countnow.cgi?')
document.write('usr=00522759&type=0"')
document.write(' hspace="30"></SCRIPT></center>')
document.write('<!-- END inlive CODE -->')
document.write('<!-- BEGIN ADDFREECOUNTER CODE -->')
document.write('<center><SCRIPT language="javascript" ')
document.write('src="http://www.addfreestats.com/cgi-bin/afc.cgi?usr=00522759">')
document.write('</SCRIPT></center>')
document.write('<!-- END ADDFREECOUNTER CODE -->')
}

function writeStats()
{
document.write('<!-- BEGIN inlive CODE -->')
document.write('<center><SCRIPT language="javascript" ')
document.write('src="http://www.addfreestats.com/cgi-bin/afstrack.cgi?')
document.write('usr=00522759">')
document.write('</SCRIPT></center>')
document.write('<!-- END inlive CODE -->')
document.write('<!-- BEGIN ADDFREECOUNTER CODE -->')
document.write('<center><SCRIPT language="javascript" ')
document.write('src="http://www.addfreestats.com/cgi-bin/afc.cgi?usr=00522759">')
document.write('</SCRIPT></center>')
document.write('<!-- END ADDFREECOUNTER CODE -->')
}



//-->

