display.php
CODE
<table border="1">
<tr><th width="70">Time</th><th width="200">IP</th><th width="70">Viewed</th></tr>
<?php
$LogData = file_get_contents("log.txt");
$Find = "/||(.*)|(.*)|(.*)||/i";
$Replace = "<tr><td>$1</td><td>$2</td><td>$3</td></tr>";
$Table = preg_replace($Find, $Replace, $LogData);
print "$Table";
?>
</table>
<tr><th width="70">Time</th><th width="200">IP</th><th width="70">Viewed</th></tr>
<?php
$LogData = file_get_contents("log.txt");
$Find = "/||(.*)|(.*)|(.*)||/i";
$Replace = "<tr><td>$1</td><td>$2</td><td>$3</td></tr>";
$Table = preg_replace($Find, $Replace, $LogData);
print "$Table";
?>
</table>
And this is whats in log.txt
CODE
||05-05-2008 12:08|127.0.0.1|1||||05-05-2008 12:00|127.0.0.1|1||||05-05-2008 12:00|127.0.0.1|1||
But it just displays like this.
http://www.tehupload.com/8758642822.png
Its ment to display it so that each one has its own row and is devided into colums.

