// Copyright Star Global

function newWindow(a) {
	a.target = "_blank";
}


function sgSwitch (name, direction) {
	// Image directory below
	directory = '/nav/';
	// Get the image file name extension
	img = document.getElementById(name);
	fileExtension = img.src.substr(img.src.lastIndexOf("."), img.src.length);
	// Show or hide the appropriate image
	switch(direction)
	{
		case 'show':
		document.getElementById(name).src = directory + name + 1 + fileExtension;
		break;

		case 'hide':
		document.getElementById(name).src = directory + name + 0 + fileExtension;
		break;
	}
	return true;
}





// jQuery for showing tooltips on 'Donate' page

jQuery.noConflict();


jQuery(document).ready(function() {

	jQuery('#crisisline').qtip({
		 content: 'The Crisis Line provides support, and information and can lead to emergency housing for women who are either experiencing abuse now, or who have in the past. Family and friends of abused women as well as professionals can also call for support and information.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})
	
	jQuery('#shelterservices').qtip({
		 content: 'The Shelter is a warm, home-like environment that accommodates up to 18 women and children. It has eight bedrooms, including an accessible room for those with mobility challenges. Children share a bedroom with their mother. On occasion, a single woman may be asked to share a room with another woman.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})
	
	jQuery('#stv').qtip({
		 content: 'Out of its community office, Transition House also offers short and long-term individual counselling for women who are currently experiencing abuse or who are survivors of abuse. In addition, support groups offer further help for women. A wide range of issues are addressed.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})
	
	jQuery('#inhouse').qtip({
		 content: 'Not all children who witness abuse grow up to be abused or become abusive, especially if they receive counselling or have a positive role model to follow. Transition House provides intervention programs that help stop the inter-generational cycle of abuse. Children are told, "it\'s not your fault, you are loveable and you are capable." They are also taught to create a safety plan.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#childrenwhowitness').qtip({
		 content: 'Individual and group counselling for children who have witnessed abuse is also available. This helps children recognize abusive behaviour, look at alternatives to violence and break the cycle of abuse. It gives them the tools to deal with their feelings and experiences. We offer both individual and group counselling for children and support for mothers. We also provide public education about the effects of witnessing abuse and facilitate dating violence prevention presentations in public schools and other children-related locations.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})
	
	jQuery('#childrenwhowitnesssummercamp').qtip({
		 content: 'For two weeks every year, youth who have witnessed abuse at home come together for an intense experience of learning and fun. This annual summer camp run by the Children Who Witness Abuse (CWWA) program is an integral part of the programming we offer for children who witness abuse here in Victoria.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#spousalassault').qtip({
		 content: 'The Spousal Assault Victim Support Program is a service available to victims of assault, threats or criminal harassment by an intimate partner or ex-partner. Clients are given support as they proceed through the criminal justice system, given referrals to community agencies and provided with short-term counselling.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#safehome').qtip({
		 content: 'Finding safe, affordable housing for women aged 45 - 65 is a challenge.<br /><br />In April 2007 the Transition House Society opened Harrison Place, a 23-unit housing project for women between 45 and 65. It provides small, independent one-bedroom suites for such women living alone. This transitional housing (up to a maximum three years stay) offers a supportive environment and programming for women rebuilding their lives.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#supportgroups').qtip({
		 content: 'The children\'s staff and volunteers provide support and counselling for children, parenting assistance and support, child care, and often just fun normal activities that the children have perhaps not experienced for a long time. A fully equipped playroom provides a haven for children to regain their childhood.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#communityed').qtip({
		 content: 'Education and training programs are provided to professionals such as social workers, lawyers, health care providers, counsellors, police groups and victim service workers. Presentations and workshops about the issue of violence and abuse against women are offered to university and college students, community groups, service clubs, church groups and businesses.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})

	jQuery('#harrisonplace').qtip({
		 content: 'Harrison Place is a 23-unit housing project for women between 45 and 65. It provides small, independent one-bedroom suites for such women living alone. This transitional housing (up to a maximum three years stay) offers a supportive environment and programming as women rebuild their lives.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})
	
	jQuery('#generalfund').qtip({
		 content: 'We are better able to fund all programs fully when donors keep their donations in the General Fund.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})	
	
	jQuery('.usedtooltip').qtip({
		 content: 'Used items are acceptable in clean and functional condition.',
		 position: {
				corner: {
					 target: 'rightMiddle',
					 tooltip: 'topLeft'
				}
		 },
		 style: {
		 	color: '#042a5e',
		 	background: '#e9f3da',
		 	border: {
			 width: 0,
			 radius: 5,
			 color: '#d2e6b1'
			 }
		 }
	})	
	
});