title: Nested tags web scraping python
body: <p>I am scraping a fixed content from a particular website. The content lies inside a nested div as shown below:</p>
  
  <pre><code>&lt;div class="table-info"&gt;
    &lt;div&gt;
      &lt;span&gt;Time&lt;/span&gt;
          &lt;div class="overflow-hidden"&gt;
              &lt;strong&gt;Full&lt;/strong&gt;
          &lt;/div&gt;
    &lt;/div&gt;
    &lt;div&gt;
      &lt;span&gt;Branch&lt;/span&gt;
          &lt;div class="overflow-hidden"&gt;
              &lt;strong&gt;IT&lt;/strong&gt;
          &lt;/div&gt;
    &lt;/div&gt;
    &lt;div&gt;
      &lt;span&gt;Type&lt;/span&gt;
          &lt;div class="overflow-hidden"&gt;
              &lt;strong&gt;Standard&lt;/strong&gt;
          &lt;/div&gt;
    &lt;/div&gt;
    &lt;div&gt;
      &lt;span&gt;contact&lt;/span&gt;
          &lt;div class="overflow-hidden"&gt;
              &lt;strong&gt;my location&lt;/strong&gt;
          &lt;/div&gt;
   &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I want to retrieve the only the content of strong inside the div 'overflow-hidden' inside the span with string value Branch. The code i've used is:</p>
  
  <pre><code>from bs4 import BeautifulSoup
  import urllib2 
  url = urllib2.urlopen("https://www.xyz.com")
  content = url.read()
  soup = BeautifulSoup(content)
  type = soup.find('div',attrs={"class":"table-info"}).findAll('span')
  print type
  </code></pre>
  
  <p>I've scraped all the span content inside the main div 'table-info', so that i can use conditional statement to retrieve the required content. But if i try to scrap the div content inside the span as :</p>
  
  <pre><code>type = soup.find('div',attrs={"class":"table-info"}).findAll('span').find('div')
  print type
  </code></pre>
  
  <p>i get error as:</p>
  
  <pre><code>AttributeError: 'list' object has no attribute 'find'
  </code></pre>
  
  <p>Can anyone please give me some idea to retrieve content of the div in the span. Thank you.
  I'm using python2.7</p>