[SOLVED] Help with manipulating anchor tag

[SOLVED] Help with manipulating anchor tag

Hi,

This might be an easy question, but I'm new to jquery and struggling with it

Here is the problem:
I have multiple <tr> tags following the below pattern:
<tr>
<td class=c1Top>
<table>
<tbody>
<tr>
<td><t/d>
<td class=c1Link>
<a href="http://mysite">Page1.html</a>
</td>
</tr>
<tbody>
</table>
</td>
</tr>

<tr>
<td class=c1Top>
<table>
<tbody>
<tr>
<td><t/d>
<td class=c1Link>
<a href="http://mysite">Page2.html</a>
</td>
</tr>
<tbody>
</table>
</td>
</tr>

<tr>
<td class=c1Top>
<table>
<tbody>
<tr>
<td><t/d>
<td class=c1Link>
<a href="http://mysite">Page3.html</a>
</td>
</tr>
<tbody>
</table>
</td>
</tr>

I need to update the href attribute so it appends the html value to the href attribute
e.g. href="http://mysite/Page1.html"
href="http://mysite/Page2.html"
href="http://mysite/Page3.html"

I tried the following, but no luck. It updates the html value of all anchor tags with the value contained in the 1st tr
$('td.c1Top table tbody tr td.ms-vb a').attr('href', $('td.c1Link table tbody tr td.ms-vb a').html());

Appreciate your help!