Req #38858 [Opn->Nab]: Feature Request: file_get_line (get a line from a file)
| From: | stas@php.net | Date: | Sun, 13 May 2012 07:59:45 +0000 |
| Subject: | Req #38858 [Opn->Nab]: Feature Request: file_get_line (get a line from a file) | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-170410@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=38858&edit=1
ID: 38858
Updated by: stas@php.net
Reported by: toasty2 at gmail dot com
Summary: Feature Request: file_get_line (get a line from a
file)
-Status: Open
+Status: Not a bug
Type: Feature/Change Request
-Package: Feature/Change Request
+Package: *General Issues
Operating System: N/A
PHP Version: 5.2.0RC4
Block user comment: N
Private report: N
New Comment:
fgets() would do what you want.
Previous Comments:
------------------------------------------------------------------------
[2006-09-16 23:31:29] toasty2 at gmail dot com
Description:
------------
It would be very very very nice to have a function in php that will find a line in a file and save
it to a variable. A function with a name such as "file_get_line" would be good.
Usage would be like:
$line = file_get_line(5);
5, being the line to retrieve. If there's any other arguments you think would be necessary or
useful, go ahead, as long as it is capable of doing the basic feature I requested, it's good!
Thank you, hope you implement it!
Have a nice day.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=38858&edit=1