Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(3)  |  Derive(0)  |  Import(2)

src/e/r/erp5-HEAD/product/ERP5/mixin/crawlable.py   erp5(Download)
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions
from Products.ERP5Type.Utils import normaliseUrl
from Products.ERP5Type.DateUtils import convertDateToHour,\
     number_of_hours_in_day, number_of_hours_in_year
    Return only url associated to the same Domain
    """
    reference_domain = urlsplit(normaliseUrl(self.asURL() or ''))[1]
    # in www.example.com or www.3.example.com
    # keep only the example.com part
    for url in self.getContentURLList():
      try:
        url = normaliseUrl(url, base_url=base_url)
      except UnicodeDecodeError:
        # Ignore wrong encoding errors

src/e/r/erp5-HEAD/product/ERP5/mixin/url.py   erp5(Download)
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions
from Products.ERP5Type.Utils import normaliseUrl
 
no_crawl_protocol_list = ['mailto', 'javascript', ]
    """
    if self.hasUrlString():
      return normaliseUrl(self.asURL(), base_url=base_url)