// QUOTES
var quotes = new Array();
quotes[0] = 'Colossians 1:16-17|For by Him [Christ] all things were created, in heaven and on earth, visible and invisible, whether thrones or dominions or rulers or authorities - all things were created through Him and for Him. And He is before all things, and in Him all things hold together.';
quotes[1] = 'Colossians 1:11-12|being strengthened with all power according to his glorious might so that you may have great endurance and patience, and joyfully giving thanks to the Father, who has qualified you to share in the inheritance of the saints in the kingdom of light.';
quotes[2] = 'Colossians 1:13-14|He has delivered us from the domain of darkness and transferred us to the kingdom of his beloved Son, in whom we have redemption, the forgiveness of sins.';
quotes[3] = 'Galatians 2:20|I have been crucified with Christ. It is no longer I who live, but Christ who lives in me.';
quotes[4] = 'Galatians 5:13|For you were called to freedom, brothers. Only do not use your freedom as an opportunity for the flesh, but through love serve one another.';
quotes[5] = 'Galatians 5:22-23|But the fruit of the Spirit is love, joy, peace, patience, kindness, goodness, faithfulness, gentleness, self-control; against such things there is no law.';

// RANDOMIZER
var num_of_quotes = quotes.length;
x = Math.floor (num_of_quotes * Math.random());

// QUOTE SETUP 
 var translation = 47; 
var len = quotes[x].length; 
var local = quotes[x].indexOf('|'); 
var quote = quotes[x].substring(local+1,len); 
var ref = quotes[x].substring(0,local); 
var verse = escape(ref); 
var link = 'http://www.biblegateway.com/passage/?search=' + verse + ';&version=' + translation + '';

// OUTPUT
document.write('<div align=left class="quoteText">');
document.write('<b><a href="' + link + '" target=_blank>' + ref + '</a></b><br />');
document.write('<i>' + quote + '</i>');
document.write('</div>');
