Example #1
0
 def getFilePath(self, site):
     u"""
     Answers the file path, based on the URL. Add '/files' to hide Python sources from view.
     The right 2 slash-parts of the site path are taken for the output (@@@ for now)
     """
     if site.e is not None:
         return TX.class2Path(site) + "/files/" + "/".join(site.e.path.split("/")[-2:])
     return None
Example #2
0
 def getFilePath(self, site):
     u"""
     Answers the file path, based on the URL. Add '/files' to hide Python sources from view.
     The right 2 slash-parts of the site path are taken for the output (@@@ for now)
     """
     if site.e is not None:
         return TX.class2Path(site) + '/files/' + '/'.join(
             site.e.path.split('/')[-2:])
     return None
Example #3
0
 def getFilePath(self, site):
     u"""
     Answers the file path, based on the URL. Add '/files' to hide Python sources from view.
     """
     fileName = site.e.path.split('/')[-1:]
     if fileName:
         fileName = '/'.join(file)
     else:
         fileName = 'index'
     return TX.class2Path(site) + '/files/' + fileName
Example #4
0
 def getFilePath(self, site):
     u"""
     Answers the file path, based on the URL. Add '/files' to hide Python sources from view.
     """
     fileName = site.e.path.split('/')[-1:]
     if fileName:
         fileName = '/'.join(file)
     else:
         fileName = 'index'
     return TX.class2Path(site) + '/files/' + fileName