0

基本的

file_get_contents('test.php')

完璧に動作します。でも、

file_get_contents('/../test.php')

結果は"file_get_contents(/../xx.php) [function.file-get-contents]: failed to open stream: No such file or directory"

ディレクトリ構造は正しいです。

4

1 に答える 1

3

あなたはディレクトリ構造が正しいと言いますが、それでも読むのは奇妙に思えます:

file_get_contents('/../test.php')

スラッシュなしで次のようにすべきではありませんか?

file_get_contents('../test.php')
于 2013-03-12T15:58:05.423 に答える