Latest JAS v1.1.0
144 plugins online

localfile download issues

The localfile (and probably localfiles and localdirectory) field don't take into account a module can be initialized from different path. Subsequently the using the module from a different path causes it to fail on "Invalid local file directory"/files/index.php since that is called from different path.


It seems logical to always consider the lock down path to the relative folder of the root and thus _path["root"] should be added in front of the file path. Note however that this can't be done during init since modules maybe cached and therefore used from different locations without the init being called again. I.e. it should either be done in postInit or at every spot where the "localpath" is used.


It may be handy to support absolute path (e.g. /some/path) in which case the _path["root"] should not be added.

JAS14DEC001
Project
JAS Core (JAS)
Rank
2
Workflow
Version
Due in version

Updates (2)

Sunday 8th of November 2015 at 13:20 :
SetFileDir should be called in postInit rather than module constructor. This way the path will be correctly setup.
Sunday 8th of November 2015 at 13:28 :
Issue updated
Workflow: Open => Closed

Files (0)

No files