hello experts i try to make a code but its not working i make a grabber of sms and i want that all the sms in this page simply copy on my own server and i try a code which not working please fix this code errors
please help me
PHP Code:
{
$match_name = preg_match('/<div class="smstext">(.*)<\/div>/i', $chunk[$i], $w);
$sms=$w[1];
$name= var_export(substr($sms, 0, 20), true).PHP_EOL;
$name=str_replace('\'','',$name);
$myFile = "sms/".$name.".txt";
$fh = fopen($myFile, 'w') or die("can't open file");
$stringData = "".$sms."-\n";
fwrite($fh, $stringData);
fclose($fh);
}
Comment