title: How to parse through script tag using python and beautifulsoup
body: <p>I am trying to extract the attributes of a frame tag which is inside <code>document.write</code> function on a page as follows:</p>
  
  <pre><code>&lt;script language="javascript"&gt;
  .
  .
  .
  document.write('&lt;frame name="nav" src="/nav/index_nav.html" marginwidth="0" marginheight="0" scrolling="no" frameborder="0" border = "no" noresize&gt;');
   if (anchor != "") {
    document.write('&lt;frame name="body" src="http://content.members.fidelity.com/mfl/summary/0,,' + cusip + ',00.html?' + anchor + '" marginwidth="0" marginheight="0" scrolling="auto" frameborder="0" noresize&gt;');
   } else {
    document.write('&lt;frame name="body" src="http://content.members.fidelity.com/mfl/summary/0,,' + cusip + ',00.html" marginwidth="0" marginheight="0" scrolling="auto" frameborder="0" noresize&gt;');
   }
   document.write('&lt;/frameset&gt;');
  
  
  // end hiding --&gt;
  &lt;/script&gt;
  </code></pre>
  
  <p><code>findAll('frame')</code> method didn't help. Is there a way to read the contents of frame tag?</p>
  
  <p>I am using python 2.5 and BeautifulSoup 3.0.8.</p>
  
  <p>I am also open to using python 3.1 with BeautifulSoup 3.1
  so long as i am able to get the results.</p>
  
  <p>Thanks</p>