Download the PHP package bchubbweb/phntm without Composer

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

phntm

A lightweight framework designed to feel like magic; handling the boring bits of a modern web application, as if something (or someone) is doing it for you.

Installation

To install require the package to your project:

Setup

Create a .htaccess file with the following contents at the base of your project

Obviously you must then add index.php in the base of your project, to start, add the following contents:

This will set up the namespace router, and determine what to do with the current request.

Next, add the Pages namespace to your composer.json pointing to the directory you wish to use, although I would recommend pages/ in the base of your project.

Then start your local server and do as you wish

Pages

pages within your pages directory should extend the bchubbweb\phntm\Resource\Page class, and have to be named Page.php, this lets the router know this namespace can be routed to.

Layouts

Similar to NextJS, phntm uses layouts to wrap around the content of a page, this is useful for things like headers and footers, shared assets and more.

The comments are used to inject the content of the page into the layout, registered assets and the profiler script if enabled.

Unlike NextJS, layouts are limited to one deep, so the closest layout in the namespace for a given page will be used.

Profiling

To use the phntm profiler pass true to the Phntm::init() function, this will profile the request and inject the profiler script into the layout.

The script then fetches the cached profile data from the /api/profiler endpoint, and displays it in a table.


All versions of phntm with dependencies

PHP Build Version
Package Version
Requires predis/predis Version ^2.2
league/container Version ^4.2
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 bchubbweb/phntm contains the following files

Loading the files please wait ....