Obtenir l'attribut href sur jQuery

J'ai quelques lignes de la table

<tr class="b_row">
    <td>
        <div class="cpt">
            <h2>
                <a href="/ref/ref/1.html">example</a>
            </h2>
        </div>
    </td>
</tr>

<!--more elements -->

<tr class="b_row">
    <td>
        <div class="cpt">
            <h2>
                <a href="/ref/two/23.html">example N</a>
            </h2>
        </div>
    </td>
</tr>

J'ai besoin d'obtenir des liens hypertexte dans l'attribut. J'utilise ce script

function openAll()
{
    $("tr.b_row").each(function(){
    var a_href = $('div.cpt').find('h2 a').attr('href');
    alert ("Href is: " + a_href);
}

Problème: la variable a_href est toujours /ref/ref/1.html

source d'informationauteur BILL