Jump to content
Fi8sVrs

Extract URLs from Google search results

Recommended Posts

  • Active Members
Posted (edited)

If you need to extract all the links / URLs from a Google search you can use the following commands:

wget -q -U "Mozilla/5.001" -O - "http://www.google.com/search?q=inurl%3Aaftershell.com&num=100&start=200" | \
grep -o '<a href="http[^"]*"'|grep -v 'search?q=cache:'|grep -v '\.google\.'|sed 's/<a href="//;s/"$//'

You can modify them to save the output or change the parameters for the languages (&hl= and &lr= ) and many more...

AfterShell.com

Edited by Fi8sVrs

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...