Sign in to follow this  
Followers 0
iamtheky

linkedin job search

1 post in this topic

#1 ·  Posted (edited)

This function will search the jobs on linkedin for the specified string and sort the return by date descending. It will then crawl the first page of results for only the ones with an apply now button (since I just use it as a lottery and to gain interview experience anyway, i dont have the want to "apply on company website"). It then opens your firefox browser with the resulting pages tabbed.

Any suggestions for speeding this routine? My next effort is to allow for it to move on to the next page of results if desired, and maybe gather enough substance from laying around on the forum for it to be worthwhile to others.

And the firefox path is a regread which could very well only be on my box, may have to edit that.

#include <Array.au3>
 
 
_ApplyNow("CISSP")
 
 
Func _ApplyNow($search)
 
$jobs = Inetget("http://www.linkedin.com/jsearch?keywords=" & $search & "&searchLocationType=Y&sortCriteria=DD" , @TempDir & "\jobs.html" , 1 , 0)
 
$jobFile = fileread(@TempDir & "\jobs.html")
 
$URL_Array = stringregexp ($jobFile , "jobs\?viewJob=&jobId=\d+" , 3)
 
$SearchArray = _ArrayUnique ($URL_Array)
 
For $i = ubound($SearchArray) - 1 to 1 step -1
 
Inetget("http://www.linkedin.com/" & $SearchArray[$i] , @TempDir & "\search.html" , 1 , 0)
 
$read = fileread(@TempDir & "\search.html")
 
If Not stringinstr($read , "Apply Now" , 1) Then
    _ArrayDelete ($SearchArray , $i)
EndIf
 
next
 
filedelete (@TempDir & "\*.html")
 
for $i = 1 to ubound($Searcharray) - 1
    $SearchArray[$i] = "http://www.linkedin.com/" & $SearchArray[$i]
Next
 
_ArrayDelete ($SearchArray , 0)
$arraystring = _ArrayToString ($Searcharray , " ")
 
run (regread("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\firefox.exe" , "") & " " & $arraystring)
 
EndFunc
Edited by boththose

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0