How to copy the anchor text and replace the href with using PHP
<p>Hello so i have about 1000 link with anchor text formated like this</p>

<pre><code>&lt;a href="1_1_3.html" &gt;my anchor text1&lt;/a&gt;
&lt;a href="1_4_8.html" &gt;my anchor text2&lt;/a&gt;
</code></pre>

<p>.... etc</p>

<p>i want to replace all the href link with their own anchor text and add .php at the end of the url</p>

<p>result must be like this :</p>

<pre><code>&lt;a href="my anchor text1.php" &gt;my anchor text1&lt;/a&gt;
&lt;a href="my anchor text2.php" &gt;my anchor text2&lt;/a&gt;
</code></pre>

<p>Thanks in advance for your time.</p>
