I have a .php file that displays a .txt from my FTP server to a webpage.
My problem is that I want to get the .php page to refresh when something is added to the .txt file.
Right now I'm using this:
<?php
header("Refresh: 5; URL=$url1");
include('filename.txt');
?>
Which refreshes the page every five seconds to see if the .txt file is modified. I dislike this method because it spams my logs of who is viewing the webpage with the same information.
I was wondering if I could modify the .php to refresh only filename.txt is modified.