Download the PHP package karelialabs/statamic-trash without Composer

On this page you can find all versions of the php package karelialabs/statamic-trash. 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 statamic-trash

Karelia Trash

A trash bin for Statamic. Buy on the Statamic Marketplace · Product page · Documentation · Support · Security · Privacy · EULA

A trash bin for the Statamic Control Panel. When someone deletes an entry, a taxonomy term, an asset, a global set, a form submission or a user, a copy goes to the trash first. Anyone allowed to can put it back with one click, in the same place it was.

Why

Statamic deletes for good. An entry's revisions are deleted with it, and on sites that store content in a database there is no git history to fall back on. Until now, an editor who deleted the wrong page had to ask a developer to dig it out of a backup.

Features

Requirements

Installation

That is all. Trash appears under Tools in the Control Panel. From now on, deletions are kept.

To show recent deletions on the dashboard, add the widget to config/statamic/cp.php:

Settings

Editors with access can change the most common settings in the Control Panel under Tools → Addons → Trash:

Settings saved in the Control Panel take priority over the config file.

Developers can publish the config file for the rest:

Option Default What it does
enabled true Switch capturing off without uninstalling (STATAMIC_TRASH_ENABLED)
disk local Filesystem disk for the trash (STATAMIC_TRASH_DISK). Use a shared disk on multi-server sites
path statamic-trash Folder on that disk
retention_days 30 Days before items are deleted for good
types all but users What is captured
exclude none Collections, taxonomies, asset containers, global sets or forms to never capture
max_asset_size 100 Largest asset (MB) to keep a copy of
on_failure allow If the trash cannot be written: allow deletes anyway and logs the error, block stops the deletion

Expired items are removed by Laravel's scheduler once a day, and also whenever the trash is opened. If your site does not run the scheduler, nothing breaks: the trash just tidies itself on the next visit.

Permissions

Under Users → Roles there is a new Trash group:

Permission Lets the user
View the trash Open the trash. They only see items they could view before, e.g. entries in collections they have view access to
Restore items Restore. Also needs the right to create that kind of item, e.g. create blog entries, upload images assets or configure globals
Delete items forever and empty the trash Use Delete Forever and Empty Trash

Super admins can do everything. Only a super admin can restore a super admin.

What is stored, and privacy

Items are stored as JSON files (plus the asset file) in storage/app/private/statamic-trash by default. Nothing leaves your server and no database is needed.

A trashed form submission or user still holds personal data until it expires or is deleted. For users, password hashes, passkeys and two-factor secrets are never stored, so a restored user must set a new password (send a reset from their user page). Users are off by default. Use a short retention period, Delete Forever or the exclude option to match your privacy policy.

Good to know

Command line

Uninstalling

Run composer remove karelialabs/statamic-trash. The stored items stay in the trash folder until you delete it.

Support

Email [email protected] with your Statamic version and the addon version. Questions and bug reports are welcome.

Licence

Commercial. A licence from the Statamic Marketplace covers one production site; development and staging copies are free. See end user licence agreement.


All versions of statamic-trash with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
statamic/cms Version ^6.30
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 karelialabs/statamic-trash contains the following files

Loading the files please wait ...