Re: file() ignores PHP tags

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



magoo wrote:
Hi NG!

I wanna output several kinds of ascii files. Two things are bothering me right now: 1. I don`t get the PHP starttag (<?php) in my output, but the ending tags. Is there anything I can to to get all of it?

2. How can I stop the browser to render HTML output, in order to get plain ascii?

$string = file_get_contents($filename_here);

echo htmlspecialchars($string, ENT_QUOTES);

--
Postgresql & php tutorials
http://www.designmagick.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux