Thanks.
this is my modified code:
now all my $filename = 'textfile.db';
i wanna insert "textfile" WITHOUT ".db" into the text file.
the script open textfile.db and insert a string "textfile" into the file and close it.
That's what i want to accomplish.
still missing the last part.
Here's my current updated code. is this correct?
<?
foreach (glob("*.db") as $filename) and (glob("*") as $filename1)) {
$fp = fopen($filename, "a");
$string = "$filename1 line\n";
$write = fputs($fp, $string);
fclose($fp);
}
?>