Download the PHP package anteris-dev/file-explorer without Composer

On this page you can find all versions of the php package anteris-dev/file-explorer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package file-explorer

Bringing a little class to your filesystem operations

This package seeks to make your filesystem operations easier by bringing in some easy-to-use verbal methods.

To Install

Run composer require anteris-dev/file-explorer

Requirements

Getting Started

To get started with this package, create a new instance of the FileExplorer class. If you pass a directory to the constructor, this will be your starting location, otherwise the current working directory is used.

Example:

Interacting with the File System

There are several methods that will help you to start interacting with the file system. These are listed below.

createDirectory( string $directory )

This method creates a new directory. If a relative path, this directory will be created relative to the current pointer. If absolute, it will be created at that location.

Example:

createAndEnterDirectory( string $directory )

Creates a new directory and sets the current context to that directory.

Example:

createFile( string $filename, $contents, bool $overwrite = false )

This method creates a new file. If a relative path, this file will be created relative to the current pointer. If absolute, it will be created at that location. Unless $overwrite is passed as true, the file will not be overwritten.

Example:

enterDirectory( string $directory )

Sets the current context of the class to this directory (think about entering a sub-folder within your file browser). If a relative path is passed, this is relative to the current directory context.

Example:

exists( string $pointer )

Returns true if the requested resource exists, otherwise false. This could be a file or directory. If the path passed is relative, this will be relative to the current directory context.

Example:

getCurrentDirectory()

Returns the current directory context of the class. This is where relative paths are resolved.

getDirectoryContents()

Returns a collection of files and directories in the current directory context.

Example:

goUp()

Sets the directory context to the parent folder.

Example:

isAbsolutePath(string $path)

Returns true if the path is absolute, otherwise false.

joinPaths(...$paths)

Joins multiple directory paths together. The end is suffixed with a forward slash, so this should not be used with filenames.

Example:


All versions of file-explorer with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4
spatie/data-transfer-object Version ^2.5
symfony/filesystem Version ^5.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package anteris-dev/file-explorer contains the following files

Loading the files please wait ....