if self.name_table.has_key(url):
return self.name_table[url]
- if url[:7] == 'mailto:' or url[:5] == 'news:':
- self.note(1, " Not checking mailto/news URL")
+ scheme = urllib.splittype(url)
+ if scheme in ('mailto', 'news', 'javascript', 'telnet'):
+ self.note(1, " Not checking %s URL" % scheme)
return None
isint = self.inroots(url)
def do_area(self, attributes):
self.link_attr(attributes, 'href')
+ def do_body(self, attributes):
+ self.link_attr(attributes, 'background')
+
def do_img(self, attributes):
self.link_attr(attributes, 'src', 'lowsrc')
def do_frame(self, attributes):
+ self.link_attr(attributes, 'src', 'longdesc')
+
+ def do_iframe(self, attributes):
+ self.link_attr(attributes, 'src', 'longdesc')
+
+ def do_link(self, attributes):
+ for name, value in attributes:
+ if name == "rel":
+ parts = string.split(string.lower(value))
+ if ( parts == ["stylesheet"]
+ or parts == ["alternate", "stylesheet"]):
+ self.link_attr(attributes, "href")
+ break
+
+ def do_object(self, attributes):
+ self.link_attr(attributes, 'data', 'usemap')
+
+ def do_script(self, attributes):
self.link_attr(attributes, 'src')
def link_attr(self, attributes, *args):