I have an index.php in d:/www/web12/index.php
there are some anchor tags in it, e.g.
<a href="/docs/corn">
<a href="/docs/mais">
I want preg_replace them into
<a href="http://localhost/web12/directory/list=corn">
<a href="http://localhost/web12/directory/list=mais">
$url = preg_replace("/docs/", "'.$HTTP_SERVER_VARS['HTTP_HOST'].'/directory/list=", $url);// Can not use `$HTTP_SERVER_VARS['HTTP_HOST']` in `preg_replace`
Preg uses /’s as a identifyer