Re: [PATCH] use file_get_contents instead fread($fp, filesize($filename))

Antony Dovgal <[email protected]>
Newsgroups gmane.comp.php.smarty.devel
Message-ID <[email protected]>
On Tue, 6 Jul 2004 10:00:21 -0700 (PDT)
boots <[email protected]> wrote:

> --- Antony Dovgal <[email protected]> wrote:
> > Regardless of the fact that this bug will be fixed (I hope), this
> > fopen-fread-filesize-fclose mess can be safely replaced by one
> > file_get_contents() calls.
> > 
> > Please, review it.
> 
> I think this has been discussed (?). A problem with file_get_contents
> is that it would increase the requirements of Smarty to PHP >= 4.3

aha, I got it. 
so maybe it worth to make some other workaround for it?
something like:

$contents = '';
while ($buf = fread($fp, 4096)) $contents .= $buf;
?

I'm not sure if this bug will be fixed and just want to make a
workaround before the real problem appears ('cos it already appeared
for me).

-- 
Wbr, 
Antony Dovgal aka tony2001
[email protected] || [email protected]

-- 
Smarty Development Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.