-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.js
More file actions
15 lines (12 loc) · 6.69 KB
/
main.js
File metadata and controls
15 lines (12 loc) · 6.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
$(document).ready(function() {
var quotes = [{"quote":"Knowledge speaks, but wisdom listens.","author":"Jimi Hendrix"},{"quote":"Glory is fleeting, but obscurity is forever.","author":"Napoleon Bonaparte (1769-1821)"},{"quote":"Moral indignation is jealousy with a halo.","author":"H. G. Wells (1866-1946)"},{"quote":"Victory goes to the player who makes the next-to-last mistake.","author":"Chessmaster Savielly Grigorievitch Tartakower (1887-1956)"},{"quote":"Don't be so humble - you are not that great.","author":"Golda Meir (1898-1978) to a visiting diplomat"},{"quote":"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.","author":"Albert Einstein (1879-1955)"},{"quote":"A lie gets halfway around the world before the truth has a chance to get its pants on.","author":"Sir Winston Churchill (1874-1965)"},{"quote":"I do not feel obliged to believe that the same God who has endowed us with sense, reason, and intellect has intended us to forgo their use.","author":"Galileo Galilei (1564-1642)"},{"quote":"Give me a museum and I'll fill it.","author":"Pablo Picasso (1881-1973)"},{"quote":"In theory, there is no difference between theory and practice. But in practice, there is.","author":"Yogi Berra"},{"quote":"I find that the harder I work, the more luck I seem to have.","author":"Thomas Jefferson (1743-1826)"},{"quote":"In the End, we will remember not the words of our enemies, but the silence of our friends.","author":"Martin Luther King Jr. (1929-1968)"},{"quote":"Each problem that I solved became a rule which served afterwards to solve other problems.","author":"Rene Descartes (1596-1650)"},{"quote":"Whether you think that you can, or that you can't, you are usually right.","author":"Henry Ford (1863-1947)"},{"quote":"Do, or do not. There is no 'try'.","author":"Yoda ('The Empire Strikes Back')"},{"quote":"Don't stay in bed, unless you can make money in bed.","author":"George Burns (1896-1996)"},{"quote":"Nothing in the world is more dangerous than sincere ignorance and conscientious stupidity.","author":"Martin Luther King Jr. (1929-1968)"},{"quote":"C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do, it blows away your whole leg.","author":"Bjarne Stroustrup"},{"quote":"A mathematician is a device for turning coffee into theorems.","author":"Paul Erdos (1913-1996)"},{"quote":"Try to learn something about everything and everything about something.","author":"Thomas Henry Huxley (1825-1895)"},{"quote":"Problems worthy of attack prove their worth by fighting back.","author":"Paul Erdos (1913-1996)"},{"quote":"If you can't get rid of the skeleton in your closet, you'd best teach it to dance.","author":"George Bernard Shaw (1856-1950)"},{"quote":"Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws.","author":"Plato (427-347 B.C.)"},{"quote":"The power of accurate observation is frequently called cynicism by those who don't have it.","author":"George Bernard Shaw (1856-1950)"},{"quote":"Everybody pities the weak; jealousy you have to earn.","author":"Arnold Schwarzenegger (1947-)"},{"quote":"Against stupidity, the gods themselves contend in vain.","author":"Friedrich von Schiller (1759-1805)"},{"quote":"Never interrupt your enemy when he is making a mistake.","author":"Napoleon Bonaparte (1769-1821)"},{"quote":"I have never killed anyone, but I have read some obituary notices with great satisfaction.","author":"Clarence Darrow (1857-1938)"},{"quote":"Human history becomes more and more a race between education and catastrophe.","author":"H. G. Wells (1866-1946)"},{"quote":"Talent does what it can; genius does what it must.","author":"Edward George Bulwer-Lytton (1803-1873)"},{"quote":"If you are going through hell, keep going.","author":"Sir Winston Churchill (1874-1965)"},{"quote":"Black holes are where God divided by zero.","author":"Steven Wright"},{},{"quote":"I'm all in favor of keeping dangerous weapons out of the hands of fools. Let's start with typewriters.","author":"Frank Lloyd Wright (1868-1959)"},{"quote":"Some cause happiness wherever they go; others, whenever they go.","author":"Oscar Wilde (1854-1900)"},{"quote":"I am ready to meet my Maker. Whether my Maker is prepared for the great ordeal of meeting me is another matter.","author":"Sir Winston Churchill (1874-1965)"},{"quote":"I shall not waste my days in trying to prolong them.","author":"Ian L. Fleming (1908-1964)"},{"quote":"When you do the common things in life in an uncommon way, you will command the attention of the world.","author":"George Washington Carver (1864-1943)"},{"quote":"I have not failed. I've just found 10,000 ways that won't work.","author":"Thomas Alva Edison (1847-1931)"},{"quote":"Blessed is the man, who having nothing to say, abstains from giving wordy evidence of the fact.","author":"George Eliot (1819-1880)"},{"quote":"Once you eliminate the impossible, whatever remains, no matter how improbable, must be the truth.","author":"Sherlock Holmes (by Sir Arthur Conan Doyle, 1859-1930)"},{"quote":"I've had a wonderful time, but this wasn't it.","author":"Groucho Marx (1895-1977)"},{"quote":"It's kind of fun to do the impossible.","author":"Walt Disney (1901-1966)"},{"quote":"We didn't lose the game; we just ran out of time.","author":"Vince Lombardi"},{"quote":"The true measure of a man is how he treats someone who can do him absolutely no good.","author":"Samuel Johnson (1709-1784)"},{"quote":"The significant problems we face cannot be solved at the same level of thinking we were at when we created them.","author":"Albert Einstein (1879-1955)"},{"quote":"A people that values its privileges above its principles soon loses both.","author":"Dwight D. Eisenhower (1890-1969)"},{"quote":"It is far better to grasp the Universe as it really is than to persist in delusion, however satisfying and reassuring","author":"Carl Sagan (1934-1996)"},{"quote":"There is more stupidity than hydrogen in the universe, and it has a longer shelf life.","author":"Frank Zappa"},{"quote":"Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.","author":"Antoine de Saint Exupery"},{"quote":"Life is pleasant. Death is peaceful. It's the transition that's troublesome","author":"Isaac Asimov"}];
$("#btnQuote").on("click", function() {
$(".myQuoteText").css("display","block");
var randq = Math.floor(Math.random() * (50 - 0)) + 0;
var myQuote = $(".myQuoteText").html("<em>"+quotes[randq].quote+"</em>");
var myAuthor = $(".myAuthorText").html(quotes[randq].author);
});
$("#btnTweet").on("click", function() {
window.open('http://twitter.com/intent/tweet?text=' + $(".myQuoteText").text() + " - by " + $(".myAuthorText").text());
});
});