Download the PHP package serjoscha87/php-request-mapper without Composer

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

PHP request-mapper / auto-router / request-to-file-resolver for pretty URLs

Packagist Total Downloads [php]() [php]() [php]()

DOC MOSTLY REMOVED (because it was written for an older approach) - I'M CURRENTLY REWORKING IT <

Implementation examples / tests:

Perhaps those examples render the complete README unnecessary.

https://github.com/serjoscha87/php-request-mapper/tree/tests

Purpose

Ever though that it can not be that hard to reflect pretty-url requets to files on your server's file-system? Well - trying it you will quickly face edge cases that will convince you of the opposite. This requets-mapper does the heavy lifting of reflecting pretty-url request to files on the local filesystem of the server while serving you a configurable abstraction layer. It can handle 404 requests out of the box so you do not have to concern about it.

The lib

I primarily wrote this for using it within a framework for more or less static websites (not apps) I wrote some time ago. But perhaps this lib can be used beyond its actual purpose.

Installation

composer require serjoscha87/php-request-mapper

.htaccess

For Apache Webservers:

the all known 'wordpress' rewrite rule which rewrites all requests to things that do not physically exist to index.php:

Nginx rewrites requests to the index.php by default - no extra rules needed.

Requirements

Simple usage Example

filesystem:

(of course the level of dir-nesting is not limited by the request-mapper)

Examples for better understanding what the request mapper does for you

considering the filesys structure given above (see "Simple usage Example"):

misc

This lib also works perfectly fine with great template engines / implementations like BladeOne


All versions of php-request-mapper with dependencies

PHP Build Version
Package Version
Requires php Version >=8.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 serjoscha87/php-request-mapper contains the following files

Loading the files please wait ....