Found a great little piece of coding that I'd like to use (I basically
wanted a random quote popping up on my homepage). What I found was a piece
of PHP coding but I cannot figure out how to use it on my page. I have
tried inserting HTML here there and everywhere but nothing shows up when I
run the page (even publishing remotely). Code is as follows:

$quotes = array(
'Impossible is a word to be found only in the
dictionary of fools.<br />&mdash; Napoleon Bonaparte',

'A person who never made a mistake never tried any
thing new.<br /> &mdash; Albert Einstein',

'Show me a thoroughly satisfied man and I will show
you a failure.<br />&mdash; Thomas A. Edison',

generate a random number between zero
and the number of quotes minus one
$rand = rand(0, (count($quotes)-1));

// output the random quote
echo $quotes[$rand];

What am I doing wrong? Or does anyone have a better/easier way to do this?
JS maybe?