AV1611 Posted January 29, 2011 Share Posted January 29, 2011 Ok, I have a log file that is written to. I only want the text file to have the last fifty lines (\n) delimited So, how do I make it delete the excess from the TOP of the file? So if it had 60 lines, I would want it to only have lines 10-60 to net 50 total. Thanks. Quote Link to comment Share on other sites More sharing options...
litebearer Posted January 29, 2011 Share Posted January 29, 2011 array_slice http://php.net/manual/en/function.array-slice.php Quote Link to comment Share on other sites More sharing options...
AV1611 Posted January 29, 2011 Author Share Posted January 29, 2011 Thanks! That should do it Quote Link to comment Share on other sites More sharing options...
AV1611 Posted January 29, 2011 Author Share Posted January 29, 2011 where's the solved button? Quote Link to comment Share on other sites More sharing options...
Ninjakreborn Posted January 30, 2011 Share Posted January 30, 2011 Bottom left hand corner of the posts, when your reviewing the posts themselves. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.