I have the following code.
<a href="/29486389/Author_-_Name_of_Song.mp3/" class="popover-with-html hidden-phone">Andra - Inevitabil va fi bine.mp3</a>
How can I replace this string, using regex, but without losing a part from string. To looks like this
<a href="melodie/Author_-_Name_of_Song.mp3.html/" class="popover-with-html hidden-phone">Author - Name of Song</a>
I know i need to use a pattern like that:
$string = 'April 15, 2003';
$pattern = '/(\w+) (\d+), (\d+)/i';
$replacement = '${1}1,$3';
Thank you very much.