Download the PHP package matthewbdaly/laravel-flatpages without Composer

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

laravel-flatpages

Build Status Coverage Status

A flatpages implementation for Laravel.

Installation

Usage

This package includes not only a model and its associated repository and decorator, but also a controller and view for handling the request. However, it does not include a route - this is because ideally the route for the flat pages should be the very last one in your routes, since it can interfere with other routes. Unless all your flat pages will live under a certain route, you should make sure the route for this is the last one executed, otherwise you will have problems with it. Don't say I didn't warn you!

The controller lives at Matthewbdaly\LaravelFlatpages\Http\Controllers\FlatpageController and your route should call the page() method, with the path passed through as the single argument:

Alternatively, you can use the middleware at Matthewbdaly\LaravelFlatpages\Http\Middleware\FlatpageMiddleware, which may be more convenient. Be aware it will run on every 404 response received, and it should be set as the last global middleware.

Overriding the view

The default view used is flatpages::base, but this almost certainly isn't what you want, so you'll need to create a new version in your project at resources\views\vendor\flatpages\base. Obviously this can extend or include other views in the usual manner.

Every flatpage object has a template field. This defaults to null, which will use flatpages::base, but you can set it to point at any other view you want to use. Your view will obviously need to use the same variables as the default one, but using this method you can create multiple views that can be used by one or more templates, meaning that part of the content can be kept in the view and part in the database. This makes the package more flexible in that you can choose which content users can manage themselves and which you can control.


All versions of laravel-flatpages with dependencies

PHP Build Version
Package Version
Requires matthewbdaly/laravel-repositories Version ^1.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 matthewbdaly/laravel-flatpages contains the following files

Loading the files please wait ....