var kudoArr = new Array(
	'"We are loving OverSite, have registered, and feel like it is starting to replace the functionality of OmniGraffle and OmniOutliner here, with even more functionality"<br><span class="attribution"> - Jean Hanks, Fusionary</span>',
	'"this software is the best thing since sliced bread!"<br><span class="attribution"> - Pete Williams, Dept of Design</span>',
	'"Oh by the way I really like your program.  It\'s awesome!"<br><span class="attribution"> - Natalie Hopkin</span>',
	'"This is the most full-featured and easy-to-use IA/wireframing/prototyping tool that I\'ve come across and frankly I\'m amazed that I\'ve taken so long to discover it..."<br><span class="attribution"> - Christian from <a href="http://www.smileycat.com/miaow/archives/001080.php">SmileyCat</a> web design blog, A Better Way to Create Information Architectures, Wireframes and Prototypes</span>', 
	'"Thank you very much for creating OverSite - from my point of view it\'s a blessing."<br><span class="attribution"> - Tony Cundiff</span>',
	'"Thanks for your support and for creating such a great product, it will definitely make my life easier in the future."<br><span class="attribution"> - Pernille Larsen, WebHouse ApS</span>',
	'"Loving OverSite"<br><span class="attribution"> - Jamie</span>',
	'"Just a note to let you know I am using oversite, and it\'s really great!"<br><span class="attribution"> - Joanna, eankadesign</span>',
	'"I absolutely love Oversite. I was spending quite a lot of time looking and looking for a software that did exactly what it does, and was puzzled that it seemed to not exist. Then I downloaded Oversite and voila! There\'s my dream software! I especially love the way it generates a map of your outline - now I don\'t have to draw it! And redraw it, etc."<br><span class="attribution"> - Jena McEwen</span>',
	'"great piece of software, perfect for what I need!"<br><span class="attribution"> - Antony</span>',
	'"Thank you so much for your help -- and for your software!  It\'s exactly what I was looking for."<br><span class="attribution"> - Clare Ellis</span>',
	'"I have been using it for a week in two different projects and I\'m impressed. Does what it says very well. Building the wireframes and prototyping the navigation is very fast and painless."<br><span class="attribution"> - alexandrecoco</span>',
	'"The more I use it, the more useful I find it."<br><span class="attribution"> - Rebecca Stymle</span>',
	'"I am impressed and find Oversite a brilliant tool for interface design for web, iPhone, Mac OSX and many to come."<br><span class="attribution"> - Erwin Abrahamase</span>',
	'"Powerful, reliable, effective and yet easy-to-use wireframe and interaction design software great for web and software developers, designers, architects, etc."<br><span class="attribution"> - Downloadtube.com editor team</span>',
        '"Version 3.1.3 rocks. It\'s great to see you are continuously adding new features!"<br><span class="attribution"> - Andrew Rosca</span>',
	'"Fantastic bit of software by the way, well done."<br><span class="attribution">- David Paton</span>',
        '"Great program by the way.. I am using it for a big application we are going to build.. used to make wireframes with Fireworks but this is way better :-)"<br><span class="attribution">- Edwin Hebbink</span>'
);

var numKudos = kudoArr.length;
var kudIdx = Math.floor(Math.random()*numKudos);
var kudAlp = 100;
var kud = null;
var ivl = 50;
var kudFfEl;
var kudTmr;

var defImgName = 'screenshots/wireframe-sm.gif';
var ilustr_topbar;
var ilustr_midbar;
var ilustr_botbar;
var ilustr_rightbar;

function selKud() {
	if (kudFfEl) kudFfEl.onclick="";
	if (kudIdx >= numKudos) {
		kudIdx = 0;
	}
	findKud();
	fadeKudOut();
}

function findKud() {
	if (kud == null) {
		kud = document.getElementById('kud');
	}
}

function fadeKudOut() {
	if (kud) {
		kudAlp -= 10;
		if (kudAlp < 0) kudAlp = 0;
		kudOpac(kudAlp);
		if (kudAlp > 0) {
			setTimeout("fadeKudOut()", ivl);
		} else {
			kud.innerHTML = kudoArr[kudIdx];
			kudIdx++;
			fadeKudIn();
		}
	}
}

function fadeKudIn() {
	if (kud) {
		kudAlp += 10;
		if (kudAlp > 100) kudAlp = 100;
		kudOpac(kudAlp);
		if (kudAlp < 100) {
			setTimeout("fadeKudIn()", ivl);
		} else {
                        resetKud();
		//	kudTmr = setTimeout("selKud()", 8000);
		//	if (kudFfEl) {
		//		kudFfEl.onclick = function() {
		//			clearTimeout(kudTmr); 
		//			selKud(); }
		//	}
		}
	}
}

function resetKud() {
        kudTmr = setTimeout("selKud()", 8000);
        if (kudFfEl) {
                kudFfEl.onclick = function() {
                       clearTimeout(kudTmr);
                       selKud(); }
        }
}

function kudOpac(perc) {
	if (kud) {
		var dcml = perc / 100;
//		var shade = (100 - perc) * 2.55;
//		kud.style.color = "rgb("+shade+","+shade+","+shade+")";

//		kud.style.filter="alpha(opacity=" + perc + ")";
//		kud.style.MozOpacity=dcml;
//		kud.style.KhtmlOpacity=dcml;
		kud.style.opacity=dcml;
	}
}

function startKud() {
	kudFfEl = document.getElementById('kudFfEl');
	findKud();
	if (kud) {
		kud.innerHTML = kudoArr[kudIdx];
	}
        kudIdx++;
        resetKud();
//        kudTmr = setTimeout("selKud()", 8000);
}

