Download the PHP package kktsvetkov/wano without Composer

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

Wano Screenshot

Wano

Wano (short for WArnings & NOtices), is a small PHP tool meant to help reporting PHP error messages.

It is meant to be very easy to use. If you have any experience with PHP error messages such as warnings and notices, you know how annoying it is to have them pop up in the middle of your printed markup, in attributes and between HTML tags, messing things up. Wano is meant to help with that.

It is also important to mention that it is a bad policy to ignore and silence PHP error messages. That has its toll on your PHP code performance. If you clean up all the warnings, notices, etc. you are going to improve the execution time of your scripts.

Basic use

In order to use it, you just need to call \Wano\Nab::register()

...and that's it. Default settings and configurations will be used and you do not have to do anything else.

How it works ?

Wano does two things:

By doing the above, you are going to have the printed HTML content without being riddled with PHP error messages, and in the same time you are still going to see them as a report appended at the end of the page. It's that simple. The idea is not to have clumsy and overdressed library, but a simple tool that its job well.

What's inside ?

As explained above, there are two tasks that Wano does: a) collects the PHP error messages and b) print them at the end of the page.

\Wano\Nab is the class that has the custom error_handler, which collects the PHP error messages.

\Wano\Display\ namespace houses the classes used to render the list of collected PHP error messages. There is the \Wano\Display\DisplayInterface interface that must be implemented if you want to create a new such "Display" class.

Advance use

Here's what you can do to step out of the default behaviour and settings.

You can choose what type of PHP error levels Wano should collect. The format is the same used for error_reporting() -- a bitmask of the error levels. This is provided as the argument for \Wano\Nab::register()

Backtraces are really helpful when you want to track how a certain PHP error message was raised. On the other hand, in some occasions for some PHP error message levels having backtraces is just overhead. Using the same bitmask format you can declare which PHP error message levels to include backtraces when they are reported:

You can change how the results are printed by creating your own \Wano\Display class. To do that you have to create a new class that is implementing the \Wano\Display\DisplayInterface interface, and then use \Wano\Nab::setDisplay() method to attach it:

This is not recommended, but if you want to, you can manually report directly into Wano, like this:

If for whatever reason you do not want to have a register_shutdown_function() print the results, you can do it manually. For that purpose you need to replace \Wano\Nab::register() with \Wano\Nab::registerErrorHandler() which will only attach the custom error_handler. Then, you are ready to print the results, you have to call \Wano\Nab::display()

Examples

You can find few examples inside the examples/ folder. Here you can see them in action:


All versions of wano with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.0
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 kktsvetkov/wano contains the following files

Loading the files please wait ....