You could also use MySQL in which case all you'd have to do is insert text into the DB and then extract it upon display. Simpler and requires less coding and work in my opinion than learning how opening, reading, writing, and closing files is done. To insert text:
mysql_query("INSERT INTO table_name VALUES('$text','$date','$author')");
Of course you could change the variables to fit your own needs. Then to extract them and display them:
<?
mysql_connect(host,username,password); //CONNECT TO MySQL
mysql_select_db(db_name); //SELECT DATABASE
$query="SELECT*FROM table_name"; //EXTRACT INFO FROM THE TABLE CONTAINING YOUR NEWS
$result=mysql_query($query); //EXECUTE QUERY
$rows=mysql_num_rows($result); //RETURN # OF ROWS
$i=0; //START LOOP COUNTER
while ($i<$rows) {
$text=mysql_result($result,$i,"text"); //GET INFO FROM DATABASE
$date=mysql_result($result,$i,"date"); //SAME ^^
$author=mysql_result($result,$i,"author"); //SAME ^^
echo $text." written on ".$date." by ".$author; //DISPLAY INFO
++$i; //INCREMENT LOOP
}
?>
You would of course have to change the variables, code, etc. to make it more efficient (if need be) and to suit your own needs. If you don't have access to MySQL, you would then of course have to use MattFaus's method of using flat-file databases.