View Single Post
Old 2023-09-14, 08:57 PM   #4
jollyhumper
That's what she said
 
jollyhumper's Avatar
 
Join Date: Feb 2012
Location: Norway
Posts: 2,485
Send a message via ICQ to jollyhumper
Quote:
Originally Posted by HowlingWulf View Post
Here you go. Just work off this.

Code:
<?php
$todayfile = date("d-m-y") . ".txt";            // 14-05-14 = 14th of May, 2014
$text = @file_get_contents($todayfile);
echo $text;
?>
I've messed around with this one, but I can't make it work.
What I want it to do:
Let's say I have 3 files named:
01.txt
02.txt
03.txt

Can I make php pull one of them by random?

J
jollyhumper is offline   Reply With Quote