diff --git a/reference/filesystem/functions/file-put-contents.xml b/reference/filesystem/functions/file-put-contents.xml index 8fac3b2d57..95e858ca62 100644 --- a/reference/filesystem/functions/file-put-contents.xml +++ b/reference/filesystem/functions/file-put-contents.xml @@ -1,5 +1,5 @@ - + file_put_contents @@ -189,30 +189,6 @@ $person = "John Smith\n"; // and the LOCK_EX flag to prevent anyone else writing to the file at the same time file_put_contents($file, $person, FILE_APPEND | LOCK_EX); ?> -]]> - - - - Using stream contexts - -array( - 'method'=>"GET", - 'header'=>"Accept-language: en\r\n" . - "Cookie: foo=bar\r\n" - ) -); - -$context = stream_context_create($opts); - -$person = "John Smith\n"; - -// Add content to the file using the HTTP headers set above -file_put_contents('people.txt', $person, NULL, $context); -?> ]]>