Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
42 lines (30 sloc) 887 Bytes
from bs4 import BeautifulSoup
import requests
import re
def thecrawler(maxpages,movie):
page = 1
searchnetnaija(movie)
while page < maxpages:
searchtoxicwap()
def searchtoxicwap():
url="www.toxicwap.com"
def searchnetnaija(movie):
search = True
while(search):
print('This works')
url1="http://www.netnaija.com/videos/movies"
sourcecode = requests.get(url1)
plain_text = sourcecode.text
soup = BeautifulSoup(plain_text,'lxml')
list = []
for link in soup.find_all('a'):
lin = link.get('href')
list.append(lin)
search = False;
for dat in list:
x = re.search(r'movies',dat)
if x:
s = r'%s' % movie
y = re.search(s,dat)
if y:
print(dat)
You can’t perform that action at this time.