Jamie Balfour

Welcome to my personal website.

Find out more about me, my personal projects, reviews, courses and much more here.

Official ZPE/YASS documentationfile_put_contents

file_put_contents (string file[, boolean append], string contents1[, string contents2, string contents3, ..., string contentsN]) ⇒ string

Writes an infinite amount of parameters to a text file. You can append text on the end by inserting the boolean append before writing the file. Note, if you do choose to do this and wish to write a boolean true or false value to the file, the preferred option is that you should use file_write("filename.txt", "", true) as the second parameter will not be recognised as append boolean.

First available: Version 1.3.2

Notes

If you choose to do append and wish to write a boolean true or false value to the file, the suggestion is that you should use file_put_contents("filename.txt", "", true) as the second parameter will not be recognised as append boolean this way.

Prior to version 1.7.6 this method was called file_write. It was renamed as the file_write method was removed.

Comments

There are no comments on this page.

New comment

Comments are welcome and encouraged, including disagreement and critique. However, this is not a space for abuse. Disagreement is welcome; personal attacks, harassment, or hate will be removed instantly. This site reflects personal opinions, not universal truths. If you can’t distinguish between the two, this probably isn’t the place for you.

file_put_contents"/>

Comments powered by BalfComment

Feedback 👍
Comments are sent via email to me.