def process_module(self, module, embeds): """ Aggregates embedded js/css files/strings """ part = module.html_head() if part: embeds['heads'].append(_utf8(part)) part = module.css_files() if part: if isinstance(part, basestring): embeds['css_files'].append(part) else: # list embeds['css_files'].extend(part) part = module.embedded_css() if part: embeds['css_inline'].append(_utf8(part)) part = module.javascript_files() if part: if isinstance(part, basestring): embeds['js_files'].append(part) else: # list embeds['js_files'].extend(part) part = module.embedded_javascript() if part: embeds['js_inline'].append(_utf8(part))
def fetch(url, *args, **kwargs): return HTTPClient(_utf8(url), *args, **kwargs).fetch()
def fetch(url, *args, **kwargs): url = _utf8(url) c = HTTPClient(url,*args, **kwargs) d = c.fetch() return d