RE: [PHP] How to include a txt file on php?

From: Date: Tue, 27 May 2003 06:51:44 +0000
Subject: RE: [PHP] How to include a txt file on php?
Groups: php.general 
Request: Send a blank email to php-general+get-149056@lists.php.net to get a copy of this message
Its working now, I've tried a different syntax. Include Thanks, Louie -----Original Message----- From: Evan Nemerson [mailto:evan@coeus-group.com] Sent: Tuesday, May 27, 2003 2:34 PM To: Miranda, Joel Louie M Cc: php-general@lists.php.net Subject: Re: [PHP] How to include a txt file on php? file returns an arrray. either do implode("", file()); or use file_get_contents() instead the readfile() Rasmus mentioned looks like this: <?php readfile('/dynamic/ree_menu.wbc'); ?> and will output directly to the browser. Look at: php.net/readfile php.net/implode php.net/file php.net/file_get_contents On Monday 26 May 2003 11:29 pm, Miranda, Joel Louie M wrote: > Rasmus, > > <?php $readfile = file("/dynamic/ree_menu.wbc"); print $readfile; ?> > > I've tried this approach, But it does not work, any Ideas? > > Thanks, > Louie > > -----Original Message----- > From: Rasmus Lerdorf [mailto:rasmus@lerdorf.com] > Sent: Tuesday, May 27, 2003 11:30 AM > To: Miranda, Joel Louie M > Cc: 'php-general@lists.php.net' > Subject: Re: [PHP] How to include a txt file on php? > > On Tue, 27 May 2003, Miranda, Joel Louie M wrote: > > Im doing some html coding's. The pages are quite huge but has the > > same contents. I wonder how do you include a text file on php? > > readfile() -- Humanity's first sin was faith; the first virtue was doubt. -Unknown

« previous php.general (#149056) next »