﻿// ==============================================
// Copyright 2004 by CodeLifter.com
// Free for all; but please leave in this header.
// ==============================================

function quoteGen(){

var Quotation=new Array() // do not change this!

// Set up the quotations to be shown, below.
// To add more quotations, continue with the
// pattern, adding to the array.  Remember
// to increment the Quotation[x] index!

Quotation[0] = "\"We are all faced with a series of great opportunities brilliantly disguised as impossible situations.\"<br />-Chuck Swindoll (Christian pastor, author, &amp; radio preacher)";
Quotation[1] = "\"Whatsoever thy hand findeth to do, do it with thy might.\"<br />-Ecclesiastes, 9:10";
Quotation[2] = "\"Half of the failures in life come from pulling one's horse when he is leaping.\"<br />-Thomas Hood";
Quotation[3] = "A Yale University management professor once said in response to one of his student's papers about proposing reliable overnight delivery service: \"The concept is interesting and well-formed, but in order to earn better than a 'C', the idea must be feasible.\" That student was Fred Smith, and he went on to be the CEO, founder, and chairman of Federal Express.";
Quotation[4] = "\"You can't change the wind. You can, however, adjust your sails.\"<br />-From a bottle of peach Honest Tea (iced tea).";
Quotation[5] = "\"Choose a job you love, and you will never have to work a day of your life\"<br />-Confucius";
Quotation[6] = "\"Optimist: The glass is half full. Pessimist: the glass is half empty. Engineer: the glass is twice as large as it needs to be.\"<br />-Unknown";
Quotation[7] = "\"...leaders can conceive and articulate goals that lift people out of their petty preoccupations and unite them in pursuit of objectives worthy of their best efforts.\"<br />-John Gardner";
Quotation[8] = "\"If I have seen farther than others, it is because I was standing on the shoulder of giants.\"<br />-Isaac Newton";
Quotation[9] = "\"In an industrial society which confuses work and productivity, the necessity of producing has always been an enemy of the desire to create.\"<br />-Raoul Vaneigem";
Quotation[10] = "\"The world ain't all sunshine and rainbows. It is a very mean and nasty place It will beat you to your knees and keep you there permanently if you let it. You, me or nobody is going to hit as hard as life. But it ain't about how hard you hit, it is about how hard you can get hit and keep moving forward, how much can you take and keep moving forward. That's how winning is done.\"<br />-Sylvester Stallone, <em>Rocky</em>";


var Q = Quotation.length;
var whichQuotation=Math.round(Math.random()*(Q-1));
document.getElementById("quoteBox").innerHTML = (Quotation[whichQuotation]);
}


//for quoteGen box positioning:

var divName = ".boxed";
var divYloc = 135;
var offset = null;
var offset2 = null;

$(function(){
    $(window).scroll(function () { 
        offset = $(document).scrollTop();
        if (offset > divYloc) offset2 = ($(document).scrollTop() - divYloc)+"px";
       	else offset2 = "0px";
        $(divName).css({top:offset2});
	    });
});