I have to convert an ereg_replace
to preg_replace
The ereg_replace code is:
ereg_replace( '\$([0-9])', '$\1', $value );
As preg is denoted by a start and end backslash I assume the conversion is:
preg_replace( '\\$([0-9])\', '$\1', $value );
As I don't have a good knowledge of regex I'm not sure if the above is the correct method to use?