I use preg_match(...) in the following code. But that is not the main issue; I can't retrieve the destination page of the URL beacuse of a browser detect redirect.
That is, my try to retrieve the page with:
//Retrieve data from website specified in $sourcelink
$wholestring = "";
$fd=fopen($sourcelink,"r");
while ($line=fgets($fd,1000)) {
$wholestring .= $line;
}
fclose ($fd);
Fails, 'cos the destination page doesn't recognize the PHP-server's fopen(...) request as a valid browser. And therefore it redirects it and the resulting $wholestring is an error-page