php parse javascript using xpath
<p>i am trying to parse the html pages using php xpath, there are some data that are inserted into html through javascript, for example </p>

<pre><code>&lt;script type="text/javascript"&gt;     
   var insertName = function() {                
       var firstName = 'Hi SomeUserName';
       $('#welcomeMessage').html(firstName)
   }
&lt;/script&gt;
&lt;h1 id="welcomeMessage"&gt;&lt;/h1&gt;
</code></pre>

<p>i want to extract the data 'hi SomeUserName' alone, is it possible to do this in php xpath? or is there a best way to do this?</p>

<p>thanks!</p>
