document.writeln('<div id="testimonials"></div>');

var comments = [];
var authors = [];

comments.push(
"After being with bitfolk for 3 years, the company continues to provide \
an unparalleled level of service.<br /> \
<br /> \
It's refreshing to find a company that focuses on satisfying the customer \
rather than providing a product and support. No matter what your problem, a \
solution will be provided, with discussion being aimed at the level of the \
individual, from the new user to the competent sysadmin. This is a reflection \
of the dedication to an individual and their needs, rather than just selling a \
package.<br /> \
<br /> \
In a word.. superb!"
);
authors.push('<a href="http://www.waitingcloud.org/">Ciemon Dunville</a>');

comments.push(
"I tested out another cheap provider first, and God they were awful! Just shows hows painless [BitFolk] makes it."
);
authors.push('Mat Johns');

comments.push(
"BitFolk provides an incredibly economically efficient and reliable \
service. In the year that I've been using BitFolk I've got zero complaint \
with the service that BitFolk provides. I've had a VPS before and the \
system was full of IO delays and reboots which I've just never experienced \
with BitFolk. I'm thoroughly happy with the service and the uptime."
);
authors.push('<a href="http://www.s5h.net">Ed Neville</a>');

comments.push(
"BitFolk is something very rare; a friendly and knowledgeable company \
that supplies exactly what I was looking for; A no-nonsense Linux \
server that I can treat as my own and configure exactly as I want. Not \
only that, I find it extremely refreshing to be able to communicate on \
a person-to-person level in an intelligent manner. Any question I've \
had has been answered politely and to the point. I'm very pleased and \
I hope I can stay with BitFolk for a long time."
);
authors.push('<a href="http://jocke.selincite.com/">Jocke Selin</a>');

comments.push(
"You've just shown why I like dealing with small companies - the \
support!"
);
authors.push('Robert Gauld');

comments.push(
"BitFolk does an outstanding job of keeping you informed as a user, \
processing any queries promptly, and the prices are frankly unbelievable. \
Without a doubt I would recommend BitFolk to anyone who is in need of a \
Linux-based server."
);
authors.push('<a href="http://robertleverington.com/">Robert Leverington</a>');

comments.push(
"I'm loving the service at BitFolk so far and plan to be here for the \
foreseeable future."
);
authors.push("Charles Yarnold");

comments.push(
"BitFolk have been a great VPS host, with rapid feedback on support \
issues and great response to problems. The pricing is great too. It \
makes me wish I had a reason to have more than one!"
);
authors.push("Tony Whitmore");

comments.push(
"My recent contact with [BitFolk] has been the first issue I've had in \
some time, probably since I joined you back in late 2006. You resolved it \
quickly, during a weekend when I'd consider it out of hours. With this in \
mind, and the good value rates you charge me, I simply want to say \
thanks.  It's a great service, I'm a happy customer."
);
authors.push("Adrian Dugan");

comments.push(
"I've had a VPS for over a year and would highly recommend any of \
BitFolk's services. Running critical services also requires connectivity \
stability in addition to host machine stability and both have surpassed \
my expectations.  Support issues are always dealt with promptly and staff \
are easily approachable and often go out of their way to help."
);
authors.push('<a href="http://docs.win-test.com/">Simon Pearson</a>');

comments.push(
"I am simply blown away by the value and performance of my BitFolk VPS. \
I'll be recommending BitFolk to all my friends."
);
authors.push('<a href="http://john-hunt.com/">John Hunt</a>');

comments.push(
"Before moving to BitFolk I had a VPS with another provider offering \
services based on user-mode-linux. My initial reason for switching to \
BitFolk was cost, however since I have switched I have noticed the \
performance is much better, even to the extent that it is noticeable in \
a SSH session."
);
authors.push('<a href="http://dgl.cx/">David Leadbeater</a>');

comments.push(
"I'm extremely happy with the level of service that I receive from \
BitFolk Ltd, and especially Andy, the VPS I have purchased is extremely \
stable, good value for money and a lot of value added services and good \
solid information are always available to me."
);
authors.push('<a href="http://www.vampire-slayers.com/">Phil Clarke</a>');

var element = document.getElementById('testimonials');

/* cross browser method to set opacity */
function setOpacity(level) {
	element.style.opacity = level;
	element.style.MozOpacity = level;
	element.style.KhtmlOpacity = level;
	element.style.filter = "alpha(opacity=" + (level * 100) + ");";
}

/* pick a random index from the array */
function randomIndex() {
	return Math.floor(Math.random() * comments.length);
}

/* rotate and create timers to fade the testimonial in */
function fadeIn() {
	element.innerHTML =
'<div class="testimonial">\
  <blockquote>\
    <p>' + comments[current] + '</p>\
  </blockquote>\
\
<p class="author">&mdash; ' + authors[current] + '</p>\
</div>';

	current = (current + 1) % comments.length;

	for (i = 0; i <= 1; i = i + 0.05) {
		setTimeout("setOpacity(" + i + ")", i * 1000);
	}

	setTimeout("fadeOut()", 19000);
}

/* create timers to fade the testimonial away */
function fadeOut() {
	for (i = 0; i <= 1; i = i + 0.05) {
		setTimeout("setOpacity(" + (1 - i) + ")", i * 1000);
	}

	setTimeout("fadeIn()", 1000);
}

/* list 'em all out */
function listAllTestimonials() {
	for (i = 0; i < comments.length; i++) {
		document.writeln('<div class="testimonial">');
		document.writeln('  <blockquote>');
		document.writeln('    <p>' + comments[i] + '</p>');
		document.writeln('  </blockquote>');
		document.writeln('');
		document.writeln('  <p class="author">&mdash; ' +
		                 authors[i] + '</p>');
		document.writeln('</div>');
	}
}
