[TYPO3-50-general] Common namings for variables with path-content
Malte Jansen
mail at maltejansen.de
Sun Jan 11 19:41:14 CET 2009
Hi @all!
If you have a variable-name, sometimes it is unclear what the variable
realy contains, because of double meanings.
There several names for a "path" aka "folder" aka "directory"
directory:
An absolute path, which must exists. (PHP: is_dir() === TRUE)
e.g. is_dir($someDirectory)
path:
Might be a relative path or a path which might not yet exist.
You have to "manipulate" the variable-content to achieve a
directory/absolute path (PHP: is_dir() === TRUE).
e.g.
is_dir($someDirectory . $somePath)
is_dir(realpath($someRelativePath))
folder:
Normally just used in the windows95-world. Shouldn't be used.
It would be nice if you always know what kind of path it is, without
looking at the API or the code.
Cheers,
Malte
More information about the TYPO3-project-5_0-general
mailing list