Skip to main content

The BingScraper is python3 package having function to extract the text and images content on search engine `bing.com`.

Project description



# Bing Scraper

The bingscraper is python3 package which extracts the text and images content on search engine bing.com.

It helps the user in a way that he/she will be getting only meaningful results and images for their search query. It does not download the ad content and hence saving data for the user.

The script working in background requests for a search term and creates directory (if not made previously) in the root directory of the script where all the content of the related particular search is stored. This script will be downloading the hypertext and hyperlink to that text and saving it to a .txt file within the directory made by itself. This directory saves the text content as well as the images downloaded using the script.

## Requirements 1. Modules:

  1. requests: For requesting content through two HTTPS Methods: GET and POST. Used GET Method.

  2. BeautifulSoup: For creating JSON like dictionary using HTML Parser. Package uses bs4.

  3. os: For checking and making directories.

  4. PIL.Image: Pillow Module. For extracting image content.

  5. io.ByteIO: For saving the extracted image using the PIL.Image.

  1. Internet Connection: Continuous high speed internet connection is required for the proper function of the python package as it continuously creates the copy of the images into the local machine.

  2. Python: Version 3.6.4 or above. This package is written in python 3.6.4

## How to use

Install the above modules. Successful import of bingscraper depends only after the above imports.

Sample code in python:

import bingscraper as bs

search = str(input())

bs.scrape(search).text() #For Text Scraping.

bs.scrape(search).image() #For Image Scraping.

scrape() takes a string argument and the .text() or .image() does the scraping work.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bingscraper-3.0.tar.gz (2.9 kB view hashes)

Uploaded Source

Built Distribution

bingscraper-3.0-py3-none-any.whl (5.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page