// JavaScript Document
//navigation start here
function mouseOver()
{
document.butn1.src ="images/home_hover_08.gif";
}
function mouseOut()
{
document.butn1.src ="images/home_06.gif";
}
 function mouseOver1()
{
document.butn2.src ="images/contactus_hover_10.gif";
}
function mouseOut1()
{
document.butn2.src ="images/contactus_08.gif";
}
 function mouseOver2()
{
document.butn3.src ="images/aboutus_10.gif";
}
function mouseOut2()
{
document.butn3.src ="images/abutus_08.gif";
}
function mouseOver3()
{
document.butn4.src ="images/profile_hover_10.gif";
}
function mouseOut3()
{
document.butn4.src ="images/profile_12.gif";
}
function mouseOver4()
{
document.butn5.src ="images/photogallery_hover_10.gif";
}
function mouseOut4()
{
document.butn5.src ="images/photogallery_12.gif";
}
function mouseOver5()
{
document.butn6.src ="images/register_hover_10.gif";
}
function mouseOut5()
{
document.butn6.src ="images/register_12.gif";
}
//***************navigation end here*******************//
//****************blink*************//
  function blinky(delay){
  var num=document.body.getElementsByTagName('SPAN')
  for(var i=0;i<num.length;i++){
         if(num[i].className=='blink'){
		 num[i].style.visibility=num[i].style.visibility=='hidden'? 'visible' : 'hidden';
		 }
      }
	  
	  setTimeout('blinky('+delay+')',delay);
  }
//***********add start here***************//  
 <!--

// set speed of banner (pause in milliseconds between characters)
var speed = 100 // decrease value to increase speed (must be positive)

// set pause between completion of message and beginning of following message
var pause = 1000 // increase value to increase pause

// set initial values
var timerID = null
var bannerRunning = false

// create global array
var ar = new Array()

// assign the strings to the array's elements
ar[0] = "Welcome to our Website of Chhatra Sangha"
ar[1] = "We hope you enjoy this Website"
ar[2] = "It is designed to be more stable than regular Website"
ar[3] = "It is designed by Designer CHIRANJIT GUHA"

// set index of first message to be displayed first
var currentMessage = 0

// set index of last character to be displayed first
var offset = 0

// stop the banner if it is currently running
function stopBanner() {
	// if banner is currently running
	if (bannerRunning)
		// stop the banner
		clearTimeout(timerID)

	// timer is now stopped
	bannerRunning = false
}

// start the banner
function startBanner() {
	// make sure the banner is stopped
	stopBanner()

	// start the banner from the current position
	showBanner()
}

// type-in the current message
function showBanner() {
	// assign current message to variable
	var text = ar[currentMessage]

	// if current message has not finished being displayed
	if (offset < text.length) {
		// if last character of current message is a space
		if (text.charAt(offset) == " ")
			// skip the current character
			offset++			

		// assign the up-to-date to-be-displayed substring
		// second argument of method accepts index of last character plus one
		var partialMessage = text.substring(0, offset + 1) 

		// display partial message in status bar
		window.status = partialMessage

		// increment index of last character to be displayed
		offset++ // IE sometimes has trouble with "++offset"

		// recursive call after specified time
		timerID = setTimeout("showBanner()", speed)

		// banner is running
		bannerRunning = true
	} else {
		// reset offset
		offset = 0

		// increment subscript (index) of current message
		currentMessage++

		// if subscript of current message is out of range
		if (currentMessage == ar.length)
			// wrap around (start from beginning)
			currentMessage = 0

		// recursive call after specified time
		timerID = setTimeout("showBanner()", pause)

		// banner is running
		bannerRunning = true
	}
}

// -->
//*************** add end here *********************//
 //***********profile banner start here*******************//
 <!--

// set speed of banner (pause in milliseconds between characters)
var speed = 100 // decrease value to increase speed (must be positive)

// set pause between completion of message and beginning of following message
var pause = 1000 // increase value to increase pause

// set initial values
var timerID = null
var bannerRunning = false

// create global array
var ar = new Array()

// assign the strings to the array's elements
ar[0] = "Welcome to our Website of Chhatra Sangha"
ar[1] = "We hope you enjoy this Website"
ar[2] = "It is designed to be more stable than regular Website"
ar[3] = "It is designed by Designer CHIRANJIT GUHA"
// set index of first message to be displayed first
var currentMessage = 0

// set index of last character to be displayed first
var offset = 0

// stop the banner if it is currently running
function stopBanner1() {
        // if banner is currently running
        if (bannerRunning)
                // stop the banner
                clearTimeout(timerID)

        // timer is now stopped
        bannerRunning = false
}

// start the banner
function startBanner1() {
        // make sure the banner is stopped
        stopBanner1()

        // start the banner from the current position
        showBanner1()
}

// type-in the current message
function showBanner1() {
        // assign current message to variable
        var text = ar[currentMessage]

        // if current message has not finished being displayed
        if (offset < text.length) {
                // if last character of current message is a space
                if (text.charAt(offset) == " ")
                        // skip the current character
                        offset++                        

                // assign the up-to-date to-be-displayed substring
                // second argument of method accepts index of last character plus one
                var partialMessage = text.substring(0, offset + 1) 

                // display partial message in text field
                document.bannerForm.bannerField.value = partialMessage

                // increment index of last character to be displayed
                offset++ // IE sometimes has trouble with "++offset"

                // recursive call after specified time
                timerID = setTimeout("showBanner1()", speed)

		// banner is running
		bannerRunning = true
        } else {
                // reset offset
                offset = 0

                // increment subscript (index) of current message
                currentMessage++

                // if subscript of current message is out of range
                if (currentMessage == ar.length)
                        // wrap around (start from beginning)
                        currentMessage = 0

                // recursive call after specified time
                timerID = setTimeout("showBanner1()", pause)

		// banner is running
		bannerRunning = true
        }
}

// -->
//**************** end here **************************//

