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

avatar

Preview.png

Imagen diseñada con canva || Image designed with canva

Hola lector de mi blog. Aquí te presento un nuevo sitio web que puedes visitar para que obtengas cobertura informativa sobre dispositivos móviles. Aquí tendrás acceso a prueba de aplicaciones, revisiones y accesorios para dispositivos móviles tanto para Android como para iOS. Claro, tambien tiene existen otras opciones sobre otros productos que ofrece el mercado tecnológico en la actualidad como gafas de realidad virtual, computación en la nube, IoT, computadores, laptops, accesorios para automatización del hogar y mucho más, todo esto está disponible en este genial sitio web con muchos tópicos centrado en el área tecnológico. Eso si, la mayor parte de su información se centra en dispositivos móviles.

Espero que puedas revisar este sitio web y dejarme tu opinión por escrito en los comentarios y con gusto te responderé. Gracias por leer esta brevísima entrega. Nos vemos en la siguiente publicación.

Enlace al sitio web: coolsmartphone.

Este script fue ejecutado con Python 3.9.13 en el sistema operativo Lubuntu 18.04.6.

Hello reader of my blog. Here is a new website you can visit to get information coverage about mobile devices. Here you will have access to app testing, reviews and accessories for mobile devices for both Android and iOS. Of course, there are also other options on other products that the technology market offers today such as virtual reality glasses, cloud computing, IoT, computers, laptops, home automation accessories and much more, all of which are available on this great website with many topics focused on the technology area. Mind you, most of its information is focused on mobile devices.

I hope you can check out this website and leave me your opinion in writing in the comments and I will be glad to answer you. Thank you for reading this short article. See you in the next post.

Link to website: coolsmartphone.

This script was run with Python 3.9.13 on Lubuntu 18.04.6 operating system.

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://www.coolsmartphone.com/page/{index}/',headers=headers) as page:
            
            coolsmartphone=await page.text() 
            coolsmartphone_raw=HTMLParser(coolsmartphone)
             
            for get_hl in coolsmartphone_raw.css('li.infinite-post > a'):

                headlines=get_hl.text(strip=True)
                links=get_hl.attributes['href']

                print(f'headlines: {headlines} links: {links}')

asyncio.run(parsing_page())

result.png


Text translated by DeepL



0 comments