because I want to find all names not only /cabel. By the way, I used,
Scrapy shell with XPath and there was no problem. Thanks again.
On Nov 29, 3:05 pm, Aaron DeVore <
aaron.dev...@gmail.com> wrote:
> Got it! This is error in the web page itself. Specifically, this
> attribute (search in a text editor to get the tag):
>
> onMouseOver="MM_swapImage('alumni','','/FCWSite/Img/alumni.gif',1);
>
> The onMouseOver attribute isn't closed by a quote mark. sgmllib (the
> underlying parser for Beautiful Soup 3.0) mangles the attribute, but
> is able to recover. Firefox does the same thing. HTMLParser instead
> dies instantly and silently.
>
> By the way, the best query in this case is:
>
> soup.find('a', href="/cabel")
>
> The 'a' allows Beautiful Soup to skip attribute matching on tags that
> aren't 'a'. Taking out the regular expression removes the overhead of
> regular expression matching.
>
> Cheers!
> Aaron DeVore
>
>
>
> On Sun, Nov 29, 2009 at 8:08 AM, Zeynel <
azeyn...@gmail.com> wrote:
> > Please see this thread in StackOverflow: