Python Forum
Scraping next page of LinkedIn jobs
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Scraping next page of LinkedIn jobs
#7
Any errors that you get with the code I supplied should only be for uninstalled packages which you can easily get with pip.
If you just don't want to work with selenium, there is perhaps an alternative.
If you are logged into Linkedin, this should work.
What I suggest is to alter the URL to proceed to the next page.
If you examine the URL that you provide, you will notice that it ends with: &pageNum=0
You may be able to modify the page number (again if logged in to Linkedin) and fetch the next page with requests.
untested code
def get_url(pageno):
    return f"https://www.linkedin.com/jobs/search?keywords=Data%20Science&location=United%20Kingdom&redirect=false&position=1&pageNum={pageno}"
You may also have to change position number as I don't know if that refers to first item to show, or item number from entire list if the latter, then this would change by incrementing by 25.

Again this may possibly work, but the only sure way is to render the JavaScript which beautifulsoup is incapable of doing.
Reply


Messages In This Thread
RE: Scraping next page of LinkedIn jobs - by Larz60+ - Dec-09-2019, 09:43 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  I am scraping a web page but got an Error Sarmad54 3 1,558 Mar-02-2023, 08:20 PM
Last Post: Sarmad54
  Scraping the page without distorting content oleglpts 5 2,579 Dec-16-2021, 05:08 PM
Last Post: oleglpts
  Scraping a page with log in data (security, proxies) iamaghost 0 2,209 Mar-27-2021, 02:56 PM
Last Post: iamaghost
  Scraping .aspx page Larz60+ 21 51,817 Mar-18-2021, 10:16 AM
Last Post: Larz60+
  Scraping Whole Page Source GJG 1 2,209 Jan-13-2021, 03:19 PM
Last Post: GJG
  use Xpath in Python :: libxml2 for a page-to-page skip-setting apollo 2 3,717 Mar-19-2020, 06:13 PM
Last Post: apollo
  Not able to login and maintain session of LinkedIn using beautifulsoup RiteshMahto 3 4,488 Dec-08-2019, 06:00 PM
Last Post: RiteshMahto
  Scraping data from ebay seller page yuvalta 3 6,090 Sep-25-2019, 04:22 AM
Last Post: sandramoraes
  Web Page not opening while web scraping through python selenium sumandas89 4 10,257 Nov-19-2018, 02:47 PM
Last Post: snippsat
  Youtube page scraping ChipsSlave 1 3,106 Jun-05-2018, 03:55 PM
Last Post: snippsat

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020