// Wtites data to a config.php-style file
// @TODO Rewrite this function to use readFromFile() and writeToFile()
-function changeDataInFile ($FQFN, $comment, $prefix, $suffix, $DATA, $seek=0) {
+function changeDataInFile ($FQFN, $comment, $prefix, $suffix, $inserted, $seek=0) {
// Initialize some variables
$done = false;
$seek++;
// Read from source file
$line = fgets ($fp, 1024);
- if (strpos($line, $search) > -1) {
+ if (strpos($line, $search) > -1) {
$next = '0';
$found = true;
} // END - if
if ($next > -1) {
if ($next === $seek) {
$next = -1;
- $line = $prefix . $DATA . $suffix . "\n";
+ $line = $prefix . $inserted . $suffix . "\n";
} else {
$next++;
}