create account

[ESP-ENG] Titulos y enlaces en hevodata || Titles and links in hevodata by pynomiems

View this thread on: hive.blogpeakd.comecency.com
· @pynomiems ·
$3.82
[ESP-ENG] Titulos y enlaces en hevodata || Titles and links in hevodata
<center>

![Preview.png](https://files.peakd.com/file/peakd-hive/pynomiems/AKwM1iRidAhKMZWGyERXRzhiyr6wJ188HM8Lam5Gn7N9MDX3yabgLp2zAYevXhs.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>

<div>

<div class="text-justify">

<pre>

import asyncio
import aiohttp
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'}

async def parsing_page():
    
    async with aiohttp.ClientSession() as session:

        for index in range(1,6): 
            
            async with session.get(f'https://hevodata.com/blog/recent-articles/page/2/',headers=headers) as page:
                
                hevodata=await page.text() 
                hevodata_html=HTMLParser(hevodata)
                 
                for hl in hevodata_html.css('.entry-title > a'):

                    h=hl.text(strip=True)
                    l=hl.attributes['href']
    
                    print(f'headlines: {h} links: {l}')

asyncio.run(parsing_page())

</pre>

</div>

<center>

![result.png](https://files.peakd.com/file/peakd-hive/pynomiems/23tGR5CtwPAR1tZ1HwcSRFcg7YAs1SdvGu5MZc1jYWqFCT7JSLRwpBb2N8Dkg8vWbjpzT.png)

![result II.png](https://files.peakd.com/file/peakd-hive/pynomiems/23t7FdJhrPMHMmKe4xrMYxPZYyoyu7rYtxqHWc5gdTN6HBH27s2cogZKmjxLd5qmp3t6h.png)

</center>

---

<center>

## Text translated by <a href="https://www.deepl.com/es/translator">DeepL</a>

</center>
👍  , ,
properties (23)
authorpynomiems
permlinkesp-eng-titulos-y-enlaces-en-hevodata-oror-titles-and-links-in-hevodata
categoryhive-148441
json_metadata{"app":"peakd/2022.11.2","format":"markdown","tags":["development","blog"],"users":[],"image":["https://files.peakd.com/file/peakd-hive/pynomiems/AKwM1iRidAhKMZWGyERXRzhiyr6wJ188HM8Lam5Gn7N9MDX3yabgLp2zAYevXhs.png","https://files.peakd.com/file/peakd-hive/pynomiems/23tGR5CtwPAR1tZ1HwcSRFcg7YAs1SdvGu5MZc1jYWqFCT7JSLRwpBb2N8Dkg8vWbjpzT.png","https://files.peakd.com/file/peakd-hive/pynomiems/23t7FdJhrPMHMmKe4xrMYxPZYyoyu7rYtxqHWc5gdTN6HBH27s2cogZKmjxLd5qmp3t6h.png"]}
created2022-11-30 00:40:09
last_update2022-11-30 00:40:09
depth0
children0
last_payout2022-12-07 00:40:09
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value3.822 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length1,621
author_reputation273,261,352,410,025
root_title"[ESP-ENG] Titulos y enlaces en hevodata || Titles and links in hevodata"
beneficiaries
0.
accountreward.app
weight10,000
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id118,720,604
net_rshares15,397,048,110,584
author_curate_reward""
vote details (3)