title: How to extract text from 'a' element with BeautifulSoup?
body: <p>I'm trying to get the text from a 'a' html element I got with beautifulsoup.
  I am able to print the whole thing and what I want to find is right there:</p>
  <pre><code>-1
  &lt;a href=&quot;/manga/tensei-shitara-slime-datta-ken-fuse&quot;&gt;Tensei Shitara Slime Datta Ken Manga&lt;/a&gt;
  -1
  </code></pre>
  <p>But when I want to be more specific and get the text from that it gives me this error:</p>
  <pre><code>  File &quot;C:\python\manga\manga.py&quot;, line 15, in &lt;module&gt;
      print(title.text)
  AttributeError: 'int' object has no attribute 'text'
  </code></pre>
  <p>Here is the code I'm running:</p>
  <pre><code>import requests
  from bs4 import BeautifulSoup
  
  URL = 'https://mangapark.net/manga/tensei-shitara-slime-datta-ken-fuse'
  page = requests.get(URL)
  soup = BeautifulSoup(page.content, 'html.parser')
  
  results = soup.find('section', class_='manga')
  
  manga_title = soup.find('div', class_='pb-1 mb-2 line-b-f hd')
  
  
  for m_title in manga_title:
      title = m_title.find('a')
      print(title.text)
  </code></pre>
  <p>I've searched for my problem but I couldn't find something that helps.</p>