Download the PHP package b13/justincase without Composer

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

TYPO3 Extension "just in case" - No matter what case your URL is, we'll hit it.

When your marketing team has accidentally pushed a campaign with mixed case URLs, they should not run into 404s.

This TYPO3 extension solves your pain - just in case.

What does it do?

By default, TYPO3 v9 is strict when you're actual page is called https://b13.com/lets-connect/ but your marketing dudes name it https://b13.com/Lets-Connect/. TYPO3 v9 saves URLs as lower-case by default.

A simple PSR-15 based middleware transforms your incoming URL into lower-case and you should be fine, as both URLs would work for the users.

Installation

Use it via composer req b13/justincase or install the Extension justincase from the TYPO3 Extension Repository.

justincase requires TYPO3 v9.5.0 or later.

Configuration

As a web developer, sometimes the team wants a 307 redirect, and sometimes to just work as everything would be lower-case.

justincase does the latter ("just pretend it works") and receives the URL, processes the URL further by default, however you can configure the extension on a per-site basis to do redirects instead, by modifying the Languages array of the site configuration yaml:

languages:
    -
    title: English
    ...
    redirectOnUpperCase: true
    # in case you want to use a status code, other than 307
    redirectStatusCode: 303

If you wish to enable redirect for all languages, add these lines at the bottom of the site configuration yaml instead:

settings:
    redirectOnUpperCase: true
    # in case you want to use a status code, other than 307
    redirectStatusCode: 303

Please note that this option only works for GET or HEAD requests.

Caveats

If specific route enhancers check on camel-case (e.g. {order}/paymentForm/) this might lead to unexpected behaviours and 404 pages.

License

As TYPO3 Core, justincase is licensed under GPL2 or later. See the LICENSE file for more details.

Background, Credits & Further Maintenance

This extension was created as a show-case on what you can do with middlewares for TYPO3 v9 and customize so many things. See https://forge.typo3.org/issues/87544 for the initial request.

TYPO3 community often requests functionality, which can be put in small and efficient extensions, and justincase does exactly that, without having to burden everything into TYPO3 Core.

justincase was initially created by Daniel Goerz and Benni Mack for b13, Stuttgart, with the nice support from Matthias Stegmann for providing the extension name.

Find more TYPO3 extensions we have developed that help us deliver value in client projects. As part of the way we work, we focus on testing and best practices to ensure long-term performance, reliability, and results in all our code.


All versions of justincase with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2 || ^8.0
typo3/cms-core Version ^9.5 || ^10.0 || ^11.0 || ^12.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 b13/justincase contains the following files

Loading the files please wait ....