[ESP-ENG] Titulos y enlaces en avcweb3 || Titles and links in avcweb3

View this thread on: d.buzz | hive.blog | peakd.com | ecency.com
·@pynomiems·
0.000 HBD
[ESP-ENG] Titulos y enlaces en avcweb3 || Titles and links in avcweb3
<center>
https://i.ibb.co/SvvL6y2/Preview.png<center>Imagen diseñada con <a href="https://www.canva.com/">canva</a> || Image designed with <a href="https://www.canva.com/">canva</a></sub>
</center>

</center>

<pre>

import httpx
from selectolax.parser import HTMLParser

headers={'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75'}

for pages in range(1,5):
    
    client=httpx.Client(headers=headers)
    avc=client.get(f'https://avc.com/category/web3/page/{pages}/',follow_redirects=True).text
    
    avc_html=HTMLParser(avc)

    for find_hl in avc_html.css('article > h2 > a'):
        
        h=find_hl.text()
        l=find_hl.attributes['href']
        
        print(f'headlines: {h} links: {l}')

</pre>
    
</div>
    
<center>
    
https://i.ibb.co/98V9vdj/Result.png
    
</center>

https://i.ibb.co/51cmXvL/Result-II.png

<center>
    
👍 , , , , ,