loop to get the href attr and put as a variable as text in html
<p>I am getting myself confused with the DOM.</p>

<p>I have this HTML:</p>

<pre><code>&lt;div class="my-list"&gt;
    &lt;div class="name"&gt;&lt;/div&gt;
    &lt;div class="title"&gt;&lt;a href="some_url"&gt;&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class="my-list"&gt;
    &lt;div class="name"&gt;&lt;/div&gt;
    &lt;div class="title"&gt;&lt;a href="some_url"&gt;&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>And this JavaScript:</p>

<pre><code>var myList = $(".my-list");
for (var i=0;  i &lt; myList.length; i++) {

    // what I want is at myList[i] to get the
    // $(".title a").attr("href") as a variable
    // and then put this variable as text
    // into the html of the $(".name") html

}
</code></pre>

<p>What is a good way to construct this?</p>
