This option will reset the home page of this site. Restoring any closed widgets or categories.

Reset

Append data to a text file using php

A simple code that shows how to append data to a flat text file using php

<?php
$File = “myfile.txt”;
$Handle = fopen($File, ‘a’);
$Data = “php\n”;
fwrite($Handle, $Data);
$Data = “mysql\n”;
fwrite($Handle, $Data);
print “Data Added”;
fclose($Handle);
?>

This should add these two names to the end of the file, so our file now contains four names:
php
mysql

VN:F [1.5.7_846]
Rating: 0.0/10 (0 votes cast)
VN:F [1.5.7_846]
Rating: 0 (from 0 votes)

Related posts:

  1. Appending string using php to a text file
  2. Store Data In Remote DataBase Using cUrl or Execute a HTTP POST Using PHP CURL
  3. Write data to a page using javascript
  4. Text Size Switching Using PHP
  5. Post Data To Another Website Using cURL In PHP

Leave a Reply

Comments (required)

Spam Protected