Download the PHP package melisplatform/melis-platform-frameworks without Composer

On this page you can find all versions of the php package melisplatform/melis-platform-frameworks. 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 melis-platform-frameworks

melis-platform-frameworks

This Module handles the execution of Third party framework and return the content as response of the request, it also provides a Service in order to make a request to the third party.

Prerequisites

This module requires melisplatform/melis-core installed. This will automatically be done when using composer.

Installing

Adding Third Party Frameworks

Third Party Frameworks are located at the root of Melis Platform application /thirdparty, inside this directory you can place your desired Frameworks.
Framework skeletons for Melis Platform can be downloaded here:
Laravel, Symfony, Lumen, Silex

Above is an example of Laravel and Symfony frameworks added to /thirdparty directory.
Note: You can decide what would be the name of the framework directory name and then apply it on your configuration below.

Third Party Framework Execution

When executing the third party framework a config data MUST be declared in the config file in order to determine the application to be executed, this can be done by adding this data array on the config file:

'index-path' must set the path of the application index.php file inside /thirdparty in the root directory. For example 'Laravel/public/index.php'. DO NOT include the /thirdparty directory in the path.

Third Party Frameworks modification

Frameworks response MUST be modified to return the response content and the status of the request, here's an example of Laravel framework integration as third party framework.

Laravel public/index.php

At the last part of the code in public/index.php file, Laravel is generating the response by calling $response->send() method from Response Object then after terminated the application by $kernel->terminate($request, $response), as code syntax below:

In the integration of third party framework instead of displaying the response and terminating in the index.php file, this will return an array of data containing the content using getContent() and status getStatusCode() from Response object.

Notice the $response->send() and $kernel->terminate($request, $response) are commented to avoid rendering the response and terminating the application.

Service and implementation

This module has a service MelisPlatformService to call in order to get a response from third party framework. By specifying the route of the request it will execute a request and return the content as the result.

Example:

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the OSL-3.0 License - see the LICENSE.md file for details


All versions of melis-platform-frameworks with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1|^8.3
melisplatform/melis-core Version ^5.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 melisplatform/melis-platform-frameworks contains the following files

Loading the files please wait ....