I am using a jQuery script that shows a random slogan from an array on page load. However I want this slogan to be changed every 6 sec. How can I do this?
http://jsfiddle.net/EA4eh/"rel=“nofollow”> 这是一种工作障碍:
$(document).ready(function () {
phrases = [
"a creative Chicago design shop",
"design is simple",
"we build fine, fine things",
"we love creating"
];
var phrase = phrases[Math.floor(Math.random()*phrases.length)]
$( #site ).text(phrase);
});