J E E - R A H L
$delim = "\n"; $quotefile = "quotes.txt"; $fp = fopen($quotefile, "r"); $contents = fread($fp, filesize($quotefile)); $quote_arr = explode($delim,$contents); fclose($fp); // generate random quote index $quote_index = (mt_rand(1, sizeof($quote_arr)) - 1); // get quote at $quote_index and return it $herequote = $quote_arr[$quote_index]; echo $herequote; ?>
« In Review
|
Main
|
Worst »
January 05, 2006
WMF
dooit, doooit
Posted by e1000 at January 5, 2006 11:48 PM
Comments
Post a comment
Name:
Email Address:
URL:
Remember personal info?
Yes
No
Comments: