get the title from a context
<p>How Do I select the title of the context? I am suppose to select it to change the title of the page.</p>

<pre><code>var handler = function(context){
    document.title = //context's title
    ....
}

//sample context from ajax request
var context = '&lt;!DOCTYPE html&gt;&lt;html&gt;\
            &lt;head&gt;&lt;title&gt;Hello&lt;/title&gt;&lt;/head&gt;\
            &lt;body&gt;\
            &lt;a href="#"&gt;Click Here&lt;/a&gt;&lt;p&gt;This is my sentence.&lt;/p&gt;\
            &lt;/body&gt;&lt;/html&gt;';

.ajax{(
    ...
    success: function(data){
                 handler(data);
             }
});
</code></pre>

<hr>

<p><strong>EDIT</strong>: I forgot the doctype just incase it's necessary. The context was from an AJAX Request.</p>
