This Flask application performs web scraping on Flipkart to retrieve product reviews based on user input. It utilizes the Flask web framework, Beautiful Soup for web scraping, and requests for making HTTP requests.
Make sure you have the following dependencies installed:
- Flask
- Flask-CORS
- requests
- BeautifulSoup4
You can install them using the following command:
pip install -r requirements.txt
-
Clone the repository:
git clone https://github.com/yourusername/your-repo.git
-
Navigate to the project directory:
cd your-repo
-
Run the Flask application:
python your_app_file.py
Replace
your_app_file.py
with the name of your Flask application file. -
Open your web browser and go to http://localhost:5000/ to access the application.
-
Access the homepage by visiting http://localhost:5000/.
-
Enter the product or content you want to search for in the provided input field.
-
Click the "Search" button.
-
The application will fetch reviews from Flipkart based on the provided input and display the results.
-
Homepage: Provides a simple user interface with an input field to enter the search query.
-
Review Page: Retrieves reviews from Flipkart for the specified product and displays them on the results page.
-
Logging: The application logs relevant information, including any errors encountered during the scraping process, into a log file (
scrapper.log
).
Feel free to open issues or contribute to the project by submitting pull requests. Your feedback and contributions are welcome!
This Flask application performs image scraping from Google based on a user's search query. It utilizes the Flask web framework, Beautiful Soup for web scraping, requests for making HTTP requests, and MongoDB for storing image data.
Make sure you have the following dependencies installed:
- Flask
- Flask-CORS
- requests
- BeautifulSoup4
- pymongo
You can install them using the following command:
pip install -r requirements.txt
- Create a MongoDB Atlas account (https://www.mongodb.com/cloud/atlas).
- Set up a cluster and obtain the connection string.
-
Clone the repository:
git clone https://github.com/yourusername/your-repo.git
-
Navigate to the project directory:
cd your-repo
-
Run the Flask application:
python your_app_file.py
Replace
your_app_file.py
with the name of your Flask application file. -
Open your web browser and go to http://localhost:8000/ to access the application.
-
Access the homepage by visiting http://localhost:8000/.
-
Enter the search query for images in the provided input field.
-
Click the "Search" button.
-
The application will fetch images from Google based on the provided query and store them in the
images/
directory. Image data will also be stored in MongoDB.
-
Homepage: Provides a simple user interface with an input field to enter the search query.
-
Image Scraping: Fetches images from Google based on the provided query and saves them in the
images/
directory. -
MongoDB Integration: Stores image data, including index and image content, in MongoDB.
-
Logging: The application logs relevant information, including any errors encountered during the scraping process, into a log file (
scrapper.log
).
Set up your MongoDB Atlas connection by replacing the MongoDB connection string in the app.py
file with your own connection string.
Feel free to open issues or contribute to the project by submitting pull requests. Your feedback and contributions are welcome!
This Flask application uses the YouTube API to fetch data from a specific YouTube channel, stores it in a CSV file, and then displays the data on a webpage. The application provides a simple interface to showcase YouTube video details.
Make sure you have the following dependencies installed:
- Flask
- google-api-python-client
- google-auth
- google-auth-oauthlib
- google-auth-httplib2
You can install them using the following command:
pip install -r requirements.txt
- Create a project on the Google Cloud Console (https://console.developers.google.com/).
- Enable the YouTube Data API v3 for your project.
- Create API credentials (API key) for your project.
-
Clone the repository:
git clone https://github.com/yourusername/your-repo.git
-
Navigate to the project directory:
cd your-repo
-
Run the Flask application:
python your_app_file.py
Replace
your_app_file.py
with the name of your Flask application file. -
Open your web browser and go to http://localhost:5000/ to access the application.
-
The application fetches YouTube data (title, published date, thumbnails, and views) from a specific channel using the YouTube API.
-
The data is stored in a CSV file named
youtube_data.csv
. -
The application then reads the CSV file and displays the YouTube data on the homepage.
-
YouTube Data Fetching: Fetches data from a specific YouTube channel using the YouTube API.
-
CSV Storage: Stores the fetched data in a CSV file for future reference.
-
Webpage Display: Displays the YouTube data on a simple webpage.
-
Error Logging: Logs any errors encountered during the process in the
scrapper.log
file.
Feel free to open issues or contribute to the project by submitting pull requests. Your feedback and contributions are welcome!