Php output current file contents without file reading functions?

You can configure Apache to serve up PHP files as formatted source code with.

You can configure Apache to serve up PHP files as formatted source code with: AddHandler application/x-httpd-php-source . Phps This'd make any . Phps files be served up as source instead of executed.

If you want a particular file to be served up, but also still be executable as an actual PHP script, you can create a symlink to it, and give the symlink a . Phps extension.

I assume this would be the most proper solution if not using raw PHP – Alex Aug 4 at 10:02.

You can always change your apache/webserver config to serve php files as text (without running the code).

No, this is not possible. You will need to use file functions to open the file and read it. If you are looking for specific properties of your code, you could try using the reflection API: php.net/manual/en/book.reflection.php If you just want to display the code, you can use the highlight_file/highlight_string functions: php.net/manual/en/function.highlight-fil....

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions