Skip to content

whoisdinanath/ekantipur-scrape

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Ekantipur News Scraper

This Python script scrapes the latest news headlines from the Ekantipur website. It uses the requests library to fetch the webpage content and BeautifulSoup from the bs4 library to parse the HTML.

Features

  • Major Headlines: Extracts and prints the major headlines from the homepage.
  • Banner Section: Extracts and prints articles from the banner section.
  • Samachar Section: Extracts and prints articles from the Samachar section.

Requirements

  • Python 3.x
  • requests library
  • beautifulsoup4 library

Installation

Install the required libraries using pip:

pip install requests beautifulsoup4

Usage

Run the script to print the latest news headlines:

python news_scraper.py

Example Output


Major Headlines:
गुल्मीमा पहिरोले घर बगाउँदा ४ जनाको मृत्यु
More: https://ekantipur.com/pradesh-5/2024/08/06/4-members-of-the-same-family-died-when-the-house-was-swept-away-by-a-landslide-in-gulmi-01-24.html

--------------------------------------------------------------

सरकारले श्वास फेर्ने हावामा कर लगाउने कानुन ल्याउन मात्रै बाँकी छ : सांसद शर्मा:
कांग्रेस सांसद डा. सुनिल शर्माले सरकारले जनताले सास फेर्ने हावामा कर लगाउने कानुन ल्याउन मात्रै बाँकी रहेको बताएका छन् ।
More: https://ekantipur.com/news/2024/08/06/all-that-is-left-for-the-government-is-to-bring-a-law-to-tax-breathing-air-mp-sharma-23-56.html
...

License

This project is licensed under the MIT License.

About

Script to scrape the news headlines from ekantipur.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages