function

valid . files . sncode

VERSIONlatest Use to validate a file or a directory.

VALID

NAME

valid - Use to validate a file or a directory.

SYNOPSIS

valid("filename");

DESCRIPTION

This function is used to validate a file or a directory. A file is valid if its below the root of the filesystem and can be stats.

The root of the filesystem is defined in the configuration file. See ExtensoConfig for more information.

EXAMPLES

Note: In the followings examples, the _ between the { should be removed to make it work.

res={_{ valid("/../../v5/html"); }}. return res=false.
res={_{ a=valid("/../v5/html"); a;}}. return res=true.
res={_{ a=valid("/noread"); a;}}. return res=true.
res={_{ a=valid("/noraead"); a;}}. return res=false.
res={_{ a=valid("/nor aead"); a;}}. return res=false.

AUTHOR

Written by Pierre Laplante, <laplante@sednove.com>