Include

Installs and manages files and packages that need to reside on the PHP include_path.

Any file not found on the default include_path is added to the local repository, which is then added to the include_path on every page load. If an error occurs, the original include_path is restored and an error flag is set to prevent further damage.

This very simple module contains only one externally useful function:

include_check_path($path, $source = NULL, $type = 'file')

Verifies or installs a file or directory into the include repository.

Parameters

$path The target path to install, relative to the include file root. If $path is empty or ends in a trailing slash, it is interpreted as a directory name, and both $source and $type are ignored.

$source (optional) The file data, or a uri where it may be found. If unset or empty, then $path is a directory name, and $type is ignored.

$type (optional) A string which determines how $source is to be interpreted. Must be one of the following:

  • 'dir' : $path is a directory name, and $source is ignored.

  • 'file' : (Default) realpath($source) is a local file.

  • 'url' : $source is a string containing the file data.

Return value

TRUE if the file was found or installed; otherwise FALSE.

Downloads

Recommended releases

Version Downloads Date Links
7.x-1.8 tar.gz (9.91 KB) | zip (12.28 KB) 2011-Sep-08 Notes
6.x-1.8 tar.gz (9.79 KB) | zip (12.15 KB) 2011-Sep-08 Notes

Other releases

Version Downloads Date Links
8.x-1.8 tar.gz (9.89 KB) | zip (12.27 KB) 2011-Sep-08 Notes

Project Information


Maintainers for Include

Issues for Include

To avoid duplicates, please search before submitting a new issue.
All issues
Bug reports
Statistics (2 years)
New issues
Open bugs
Participants
nobody click here