function CheckForm(){

  var Email			=	document.login.email.value;
  var Password			=	document.login.password.value;
  var Password_length		=	Password.length;




	AtPos 			= 	Email.indexOf("@")
	StopPos 		= 	Email.lastIndexOf(".")




	if (Email == "") 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (AtPos == -1 || StopPos == -1) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (StopPos < AtPos) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (StopPos - AtPos == 1) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	} 
  
	if(Password_length < 6) 
	{
		alert('Password length must be at least 6 Characters in Length.\nPlease adjust, Thank You.');
		return false;
	}
}



function CheckPurchaseForm(){

  var Email			=	document.login.email.value;




	AtPos 			= 	Email.indexOf("@")
	StopPos 		= 	Email.lastIndexOf(".")




	if (Email == "") 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (AtPos == -1 || StopPos == -1) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (StopPos < AtPos) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	}

	if (StopPos - AtPos == 1) 
	{
		alert('Not a valid email address entered.\nPlease adjust. Thank You.');
		return false;
	} 

}



function init() {
  if (arguments.callee.done) return;
  arguments.callee.done = true;
  if (_timer) clearInterval(_timer);
  start();
};
if (document.addEventListener) {
    document.addEventListener("DOMContentLoaded", init, false);
}
/*@cc_on @*/
/*@if (@_win32)
    document.write("<script id=__ie_onload defer src=javascript:void(0)><\/script>");
    var script = document.getElementById("__ie_onload");
    script.onreadystatechange = function() {
        if (this.readyState == "complete") {
            init(); // call the onload handler
        }
    };
/*@end @*/
if (/WebKit/i.test(navigator.userAgent)) {
    var _timer = setInterval(function() {
        if (/loaded|complete/.test(document.readyState)) {
            init();
        }
    }, 10);
}
window.onload = init;
function uu(el) {
  return document.getElementById(el);
}
function start() {
  initialise('show-hide-details-div', true);
  initialise('show-hide-keywords-div', true);
  initialise('show-hide-formats-div', true);
  initialise('show-hide-email-div', true);
  initialise('show-hide-sms-div', true);
  initialise('show-hide-anitailor-div', true);
  initialise('show-hide-token-div', true);
};
function initialise(el, doToggle) {
  if(!document.getElementById) return;
  targetEl = uu(el);
  if(targetEl) {
    addEvent(targetEl, 'click', toggle);
    targetEl.style.cursor = 'pointer';
    if(doToggle){
      targetEl.className = 'hide';
      var temp = new Array();
      temp = el.split('show-hide-');
      uu(temp[1]).className = 'hideMe';
    }
  }
};
toggle = function(e) {
  this.className = (this.className == 'show') ? 'hide' : 'show';
  var temp = new Array();
  temp = this.id.split('show-hide-');
  var targetElement = uu(temp[1]);
  targetElement.className = (targetElement.className == 'showMe') ? 'hideMe' : 'showMe';
};
// written by Dean Edwards, 2005
// with input from Tino Zijdel - crisp@xs4all.nl
// http://dean.edwards.name/weblog/2005/10/add-event/
function addEvent(element, type, handler)
{
	if (element.addEventListener)
		element.addEventListener(type, handler, false);
	else
	{
		if (!handler.$$guid) handler.$$guid = addEvent.guid++;
		if (!element.events) element.events = {};
		var handlers = element.events[type];
		if (!handlers)
		{
			handlers = element.events[type] = {};
			if (element['on' + type]) handlers[0] = element['on' + type];
			element['on' + type] = handleEvent;
		}
	
		handlers[handler.$$guid] = handler;
	}
}
addEvent.guid = 1;

function removeEvent(element, type, handler)
{
	if (element.removeEventListener)
		element.removeEventListener(type, handler, false);
	else if (element.events && element.events[type] && handler.$$guid)
		delete element.events[type][handler.$$guid];
}

function handleEvent(event)
{
	event = event || fixEvent(window.event);
	var returnValue = true;
	var handlers = this.events[event.type];

	for (var i in handlers)
	{
		if (!Object.prototype[i])
		{
			this.$$handler = handlers[i];
			if (this.$$handler(event) === false) returnValue = false;
		}
	}

	if (this.$$handler) this.$$handler = null;

	return returnValue;
}

function fixEvent(event)
{
	event.preventDefault = fixEvent.preventDefault;
	event.stopPropagation = fixEvent.stopPropagation;
	return event;
}
fixEvent.preventDefault = function()
{
	this.returnValue = false;
}
fixEvent.stopPropagation = function()
{
	this.cancelBubble = true;
}

// This little snippet fixes the problem that the onload attribute on the body-element will overwrite
// previous attached events on the window object for the onload event
if (!window.addEventListener)
{
	document.onreadystatechange = function()
	{
		if (window.onload && window.onload != handleEvent)
		{
			addEvent(window, 'load', window.onload);
			window.onload = handleEvent;
		}
	}
}



// ANITAILOR BIT
function go_to_step0()
{
	document.getElementById("anitailor1").style.display='block';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='none';
}


function go_to_step1()
{
	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='block';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='none';
}

function go_to_step2()
{
	var storyboard = document.getElementById("storyboard").value;

	if(storyboard == "")
		{
		alert('You must enter text into the storyboard before you can continue. \nThank You!');
		return false;
		}

	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='block';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='none';
}


function go_to_step3()
{
	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='block';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='none';
}


function go_to_step4()
{
	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='block';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='none';
}


function go_to_step5()
{
	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='block';
	document.getElementById("anitailor7").style.display='none';
}


function go_to_step6()
{
	document.getElementById("anitailor1").style.display='none';
	document.getElementById("anitailor2").style.display='none';
	document.getElementById("anitailor3").style.display='none';
	document.getElementById("anitailor4").style.display='none';
	document.getElementById("anitailor5").style.display='none';
	document.getElementById("anitailor6").style.display='none';
	document.getElementById("anitailor7").style.display='block';
}


function go_to_step7()
{

	alert('finished');
}


