I'm in a bit of a bind and I'm wondering if another forum user who's quite into scripting can help me out. I'm sure it's something obvious, but I can't think what it is. Basically, this script is meant to loop through selected items and 'regexreplace' each file's contents. Here's what I came up with
Code: Select all
"Text Loop"
$filelist = getinfo('SelectedItemsPathNames', '|');
$p = strpos($filelist, '|');
while ($p >= 0)
{
$filelist = substr($filelist, $p + 1);
regexreplace $data, readfile("<curitem>"), "\n", "<crlf>";
writefile("<curitempath>\<curbase>.nfo", "$data");
}
However, running this script on selected items shows an error message that says that "
File missing!" on line "
regexreplace $data, readfile("<curitem>"), "\n", "<crlf>";" I'd appreciate if someone can enlighten me why that is, thank you
