window.onload = function() {
    if (!document.getElementsByTagName)
        return;

    var a, i = 0;
    while ((a = document.getElementsByTagName("a")[i++])) {
        if ("#top" == a.getAttribute("href")) {
            a.onclick = function() { backToTop(); return false; }
        }
    }
}



function backToTop() {
    var x1 = x2 = x3 = 0;
    var y1 = y2 = y3 = 0;

    if (document.documentElement) {
        x1 = document.documentElement.scrollLeft || 0;
        y1 = document.documentElement.scrollTop || 0;
    }

    if (document.body) {
        x2 = document.body.scrollLeft || 0;
        y2 = document.body.scrollTop || 0;
    }

    x3 = window.scrollX || 0;
    y3 = window.scrollY || 0;

    var x = Math.max(x1, Math.max(x2, x3));
    var y = Math.max(y1, Math.max(y2, y3));

    window.scrollTo(Math.floor(x / 2), Math.floor(y / 2));

    if (x > 0 || y > 0) {
        window.setTimeout("backToTop()", 25);
    }
}

function randomQuote() {
	var r_text = new Array();
	r_text[0]="<img src=\"images/subtitle-ease.gif\" /> " +
		"<p class=\"quote\"> " +
		"	Snowbird is clear about where they stand; providing debt, not equity &ndash; and are very straightforward about it.  It is a good model for people. " +
		"</p>" +
		"<p class=\"author\">" +
		"	-  Steward Christ<br />" +
		"	<em>mystockfund.com</em>" +
		"</p>";        
	r_text[1]="<img src=\"/images/h-entrepreneurship.gif\" height=\"35\" width=\"151\" alt=\"entrepreneurship\" /> " +
		"<p class=\"quote\"> " +
		"	Snowbird understands what it takes to be an entrepreneur. They are innovators who are interested in working with other innovators who are underserved by banks and VC's. Snowbird sees potential where others may not and can personally relate to issues faced by entrepreneurs. " +
		"</p>" +
		"<p class=\"author\">" +
		"	- Greg Botto<br />" +
		"	<em>President &amp; CEO</em> <br />" +
		"	<em>GNS Network Services, Inc.</em>" +
		"</p>";
	r_text[2]="<img src=\"images/h-people.gif\" height=\"39\" width=\"106\" alt=\"people\" /> " +
		"<p class=\"quote\"> " +
		"	Throughout the application process, we worked with a core team, understood who the decision makers were, and received clear and straightforward answers from beginning to end. " +
		"</p>" +
		"<p class=\"author\">" +
		"	- Greg Botto<br />" +
		"	<em>President &amp; CEO</em> <br />" +
		"	<em>GNS Network Services, Inc.</em>" +
		"</p>"; 
	r_text[3]="<img src=\"images/subtitle-ease.gif\" /> " +
		"<p class=\"quote\"> " +
		"	Snowbird is clear about where it stands: providing debt, not equity - and is very straightforward about it. It is a good model for people whose bank isn't going to provide additional funding - a good fit for companies who like the approach. " +
		"</p>" +
		"<p class=\"author\">" +
		"	-  Stewart Christ<br />" +
		"	<em>President &amp; CEO </em> <br />" +
		"	<em>MYSTOCKFUND.com</em>" +
		"</p>"; 
	r_text[4]="<img src=\"/images/h-certainty.gif\" height=\"35\" width=\"151\" alt=\"entrepreneurship\" /> " +
		"<p class=\"quote\"> " +
		"	Snowbird Capital didn't spring any last minute surprises and stuck to their timelines. Those two factors made it very easy to work with them. " +
		"</p>" +
		"<p class=\"author\">" +
		"	- Greg Botto<br />" +
		"	<em>President &amp; CEO</em> <br />" +
		"	<em>GNS Network Services, Inc.</em>" +
		"</p>"; 
    
	var i = Math.round(4*Math.random());

	document.write(r_text[i]);
}