[SOLVED] change url in variable
Posted: Wed Mar 21, 2007 9:24 am
Hi all
I' need to change link inside variable with another link
example
$some_text = 'some text some text some text some text <a href=\"http://www.someurl.com/somedirectory/so ... php\">some text</a> some text some text some text <a href=\"http://www.someotherurl.com/someotherdi ... php\">some text</a> some text';
for each links in $some_text should be replaced with "http://" . $_SERVER['HTTP_HOST'] . /stranice/preg_str.php
if somebody coul point me in right direction
regards
ddragas
I' need to change link inside variable with another link
example
$some_text = 'some text some text some text some text <a href=\"http://www.someurl.com/somedirectory/so ... php\">some text</a> some text some text some text <a href=\"http://www.someotherurl.com/someotherdi ... php\">some text</a> some text';
for each links in $some_text should be replaced with "http://" . $_SERVER['HTTP_HOST'] . /stranice/preg_str.php
if somebody coul point me in right direction
regards
ddragas