How can I use the file_put_contents function to write a string to a file in PHP? Example code: - Biz Tech

How can I use the file_put_contents function to write a string to a file in PHP? Example code:

Listen
$file_contents = "Hello World!";

file_put_contents("example.txt", $file_contents);