2017 © Pedro Peláez
 

library stack-zf2

Run Zend Framework on a Symfony HTTP kernel

image

reenl/stack-zf2

Run Zend Framework on a Symfony HTTP kernel

  • Saturday, July 1, 2017
  • by reenl
  • Repository
  • 1 Watchers
  • 12 Stars
  • 11 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

== THIS REPOSITORY IS OUTDATED ==

This repository was created way back when PSR-7 wasn't a thing. I would advise you to use PSR-7 as intermediate request format. Most stack middleware is already available for PSR-7., (*1)

The most common PSR-7 implementation can be found here. After that you should search for bridges to make it compatible with your framework if it isn't already., (*2)

== Original Content Below ==

Stack/ZF2

This project runs a ZF2 project within the Symfony Http Foundation wich is even more fun when Stack comes into the picture., (*3)

Installation

Install Zend Framework using composer and simply add the require: "reenl/stack-zf2": "dev-master". Then run composer update., (*4)

Please take a look at [QUICKSTART.md] (QUICKSTART.md) for a more detailed description., (*5)

Why stack/zf2?

Because it can be done. I wanted to investigate how flexible ZF2 is versus SF. It helped me understand the inner workings of Zend Framework., (*6)

However it can be useful in several other cases:, (*7)

  • Gracefully migrate from Zend Framework to Symfony or the other way around.
  • Ability to use (hopefully all) the stack middlewares.
  • Find bugs in ZF2.

Todo

  • Find out how to handle chdir, probably a setter on our kernel. (Please twitter me if you know the dependencies for chdir.)
  • Test cases.
  • Test compatibility other stack components.
  • ~~Find out what to do with Request::getBasePath. Hardcoded usage in some helper.~~
  • ~~Conversion from Symfony to Zend Request is via toString.~~
  • ~~Try to make ZF throw exceptions instead of an error page when $catch is false.~~

Known issues

  • Application must be bootstrapped before calling ::handle.
  • The request object can not be used during bootstrap, because the request that is going to be handled is not known when bootstrapping.
  • $_ENV and $_FILES are not (yet) supported.

Support

  • Open a ticket
  • twitter: https://twitter.com/justreenl

Contribute

  • Optional: create an issue to notify me what you are doing
  • Fork
  • Improve
  • PR

The Versions

01/07 2017

dev-master

9999999-dev

Run Zend Framework on a Symfony HTTP kernel

  Sources   Download

MIT

The Requires

 

The Development Requires

by Reen Lokum

stack zf2