An automation python script which will take images, titles and description from reddit and post it in Facebook post
Web scraping popular posts from a subreddit
First, we need to fetch hot posts at any given time from a subreddit.For me, r/ProgrammerHumor is a valid candidate for coders, because they are about memes and jokes related to coding and software development in general.
Import the praw module in your Python program.
Setup the Reddit API by adding the information of client_id, client_secret and user_agent.
Download the necessary information of the subreddit you desire(ProgrammerHumour in my case).
I will be making use of Selenium Web Driver, which works on the browser directly and uses the browser’s in-built features to trigger the automation test written by the tester.I will be writing a script that fetches and interacts with the web elements.
For example, suppose you need to log in to your FB account. For doing so, you need to fill in your username and password in the browser and press the login button or press the enter key on your keyboard. For achieving the same using Selenium Web Driver, you’ll have to select the text box elements of username and password, send the respective keys, which are basically your username and password and then send the enter key command.
All of the necessary commands is written using a Selenium supported programming language that is Python.
At the after uplading the photo it will print photo uploaded