|
Posted by Stefan Bellon on 02/10/06 22:37
Erwin Moller wrote:
> $myLines = file('path/to/.htaccess');
> foreach($myLines as $oneLine){
> echo htmlentities($oneLine)."<br>";
> }
>
> Does that show correctly?
This does print the content correctly, yes, thanks a lot. However, if I
want to parse (and replace) the content using ereg_replace I get funny
results as the bracket < seems to be represented as < internally.
So, when trying to get at the filename, I need to do something like
ereg_replace("<Files (.*)>", "\\1", htmlentities($line))
Wow. Is this the easiest way of filtering out the information? All I
want to do is build a list of "who may access which file according to
the information inside the .htaccess file".
--
Stefan Bellon
[Back to original message]
|