I use this code to get the source of line 25 of dragcave.net.
PHP Code:
$lines = file('http://dragcave.net/user/Christian271');
$line = $lines[25];
I need to delete all
Code:
<td><a href="/viewdragon/HkLG">View</a></td>
from it but the HkLG is going to be different every time.
I tried this
PHP Code:
$re = '';
$pattern = '/(<td><a href="/viewdragon/)....(">View</a></td>)/';
$line2 = preg_replace($pattern, $re, $line);
echo($line2);
but I get the error '
Warning: preg_replace() [
function.preg-replace]: Unknown modifier 'v' in
/home/a9196005/public_html/test.php on line
16' line 16 is $line2 = preg_replace($pattern, $re, $line); Any ideas?