Bug #76288 [Opn->Nab]: I cannot open .txt files with file_get_contents, but I can open other files.
| From: | requinix@php.net | Date: | Mon, 30 Apr 2018 14:33:44 +0000 |
| Subject: | Bug #76288 [Opn->Nab]: I cannot open .txt files with file_get_contents, but I can open other files. | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-214993@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=76288&edit=1
ID: 76288
Updated by: requinix@php.net
Reported by: im_not_gonna_tell_ya at yahoo dot com
Summary: I cannot open .txt files with file_get_contents, but
I can open other files.
-Status: Open
+Status: Not a bug
Type: Bug
Package: *General Issues
Operating System: Linux
PHP Version: 7.2.5
Block user comment: N
Private report: N
New Comment:
I can't tell you what's wrong but I can tell you that this is not a bug in PHP. Keep
looking.
Previous Comments:
------------------------------------------------------------------------
[2018-04-30 14:32:38] spam2 at rhsoft dot net
for sure not - php don't care about extensions or file-types here
set error_repprting to E_ALL and look at your errors
pretty sure your test-script is not what you are running in reality
------------------------------------------------------------------------
[2018-04-30 14:28:24] im_not_gonna_tell_ya at yahoo dot com
Description:
------------
---
From manual page: http://www.php.net/features.commandline.io-streams
---
Test script:
---------------
#This works fine
$x = file_get_contents('example.html');
#This does NOT work
$x = file_get_contents('example.txt');
#Both files exist on the server and have exactly the same content and permissions
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=76288&edit=1