PHP Classes

File: tail-usage.php

Recommend this page to a friend!
  Classes of Arthur Tumanyan   shagaTail   tail-usage.php   Download  
File: tail-usage.php
Role: Example script
Content type: text/plain
Description: example script
Class: shagaTail
Get the last lines of a file like the tail command
Author: By
Last change:
Date: 17 years ago
Size: 238 bytes
 

Contents

Class file image Download
<?
 
//
 // tail-usage.php
 //
 //
 
require_once("shagaTail.php");
 
$myShaga = new shagaTail;
 
$myShaga->tailFile = 'filename.log';
 for(;;){
    
$line = $myShaga->getStr();
     echo
$line."<br />\n";
    
$myShaga->update();
 }
 
?>