Download the PHP package rasmusgodske/flashbeep without Composer

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

FlashBeep

FlashBeep is a flexible flash messaging system for Laravel applications. It allows easy integration and customization of flash messages across your application, supporting dynamic instantiation, named parameters, and predefined message types.

FlashBeep makes it easy to create flash messages using the flashMessage helper function. The function takes a message object and stores it in the session for display in your views.

Features

Installation

Use Composer to install FlashBeep into your PHP project:

Configuration

After installing the package, comes with a default configuration file. You can publish the configuration file using the following command:

Edit the config/flash_messages.php to set up your message types and session keys:

To add a custom message type see the Creating Custom Message Types section.

Usage

You can use the flashMessage function to create and flash a message instantly.

Here are some examples of how you can create and flash messages in your controllers:

Displaying Messages

To display the flashed messages in your views, you can use the getFlashMessages().

getFlashMessages() simply returns an array of FlashMessageInterface objects. As seen here:

Using with Laravel Blade

Here is an example of how you can display the flashed messages in a Laravel Blade view:

[!CAUTION] This has not been tested yet.

Using with InertiaJS

Here is an example of how you can pass the flash messages to inertia using the HandleInertiaRequests Middleware.

Creating Custom Message Types

The easiest way to create a custom message type is to extend the AbstractFlashMessage class and add your your attributes using $this->setAttribute('key', 'value'). Here is an example of a custom message type:

To make your FlashMessage available to use with the flashMessage function, you need to add it to the config/flash_messages.php file:

Now you can use your custom message type like this:

Or without adding it to the configuration file:


All versions of flashbeep with dependencies

PHP Build Version
Package Version
Requires php Version ^7.4 || ^8.0
laravel/framework Version ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0 || ^11.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 rasmusgodske/flashbeep contains the following files

Loading the files please wait ...