Question:Consider the following script. Which PHP function best approximates its behaviour?
<?php
function my_funct ($file_name, $data)
{
    $f = fopen ($file_name, 'w');
    fwrite ($f, $data);
    fclose ($f);
}
?>
[
 

A file_get_contents() 

B file_put_contents() 

C There is no equivalent function in PHP 

D file() 

E fputs() 

+ Answer
+ Explanation
+ Report
Total Preview: 941

Copyright © 2024. Powered by Intellect Software Ltd