summaryrefslogtreecommitdiffstats
path: root/user_guide
diff options
context:
space:
mode:
authoradmin <devnull@localhost>2006-09-02 19:19:54 +0200
committeradmin <devnull@localhost>2006-09-02 19:19:54 +0200
commitb64b0be2dba3b342b70002b02305342e7f4e7ea4 (patch)
tree1cfb107c4c805c99fc606323c44132bfed1e2290 /user_guide
parente0d85bf837a59e74054260346867aec8329565c0 (diff)
Diffstat (limited to 'user_guide')
-rw-r--r--user_guide/helpers/file_helper.html6
1 files changed, 6 insertions, 0 deletions
diff --git a/user_guide/helpers/file_helper.html b/user_guide/helpers/file_helper.html
index c6b049b27..6970dd586 100644
--- a/user_guide/helpers/file_helper.html
+++ b/user_guide/helpers/file_helper.html
@@ -103,6 +103,12 @@ else<br />
&nbsp;&nbsp;&nbsp;&nbsp; echo 'File written!';<br />
}</code>
+<p>You can optionally set the write mode via the third parameter:
+
+<code>write_file('./path/to/file.php', $data, <var>'r+'</var>);</code>
+
+<p>The default mode is <kbd>wb</kbd>. Please see the <a href="http://php.net/fopen">PHP user guide</a> for mode options.</p>
+
<p>Note: In order for this function to write data to a file its file permissions must be set such that it is writable (666, 777, etc.).
If the file does not already exist, the directory containing it must be writable.</p>