Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix broken IMDB searching.

Replacing the ; with & URL parameter separators lets the IMDB search work again.
  • Loading branch information...
commit a265fcad76ea615b2a4753fa40010aa7eda49709 1 parent 2cb84f0
@brycied00d brycied00d authored
Showing with 4 additions and 2 deletions.
  1. +4 −2 library/imdb/parser/http/__init__.py
View
6 library/imdb/parser/http/__init__.py
@@ -424,7 +424,8 @@ def _get_search_content(self, kind, ton, results):
if isinstance(ton, unicode):
ton = ton.encode('utf-8')
##params = 'q=%s&%s=on&mx=%s' % (quote_plus(ton), kind, str(results))
- params = 's=%s;mx=%s;q=%s' % (kind, str(results), quote_plus(ton))
+ ##params = 's=%s;mx=%s;q=%s' % (kind, str(results), quote_plus(ton))
+ params = 's=%s&mx=%s&q=%s' % (kind, str(results), quote_plus(ton))
if kind == 'ep':
params = params.replace('s=ep;', 's=tt;ttype=ep;', 1)
cont = self._retrieve(imdbURL_find % params)
@@ -434,7 +435,8 @@ def _get_search_content(self, kind, ton, results):
return cont
# The retrieved page contains no results, because too many
# titles or names contain the string we're looking for.
- params = 's=%s;q=%s;lm=0' % (kind, quote_plus(ton))
+ ##params = 's=%s;q=%s;lm=0' % (kind, quote_plus(ton))
+ params = 's=%s&q=%s&lm=0' % (kind, quote_plus(ton))
size = 22528 + results * 512
return self._retrieve(imdbURL_find % params, size=size)
Please sign in to comment.
Something went wrong with that request. Please try again.