Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins from 3rd party packages can't be loaded. #3

Open
zero2one opened this issue Nov 16, 2018 · 1 comment
Open

Plugins from 3rd party packages can't be loaded. #3

zero2one opened this issue Nov 16, 2018 · 1 comment

Comments

@zero2one
Copy link

zero2one commented Nov 16, 2018

The plugin loader does not load plugins from 3rd party packages (eg. https://github.com/AMOSoft/zf1-extras).

This because the loader is checking if the class exists without allowing autoload to work.
This is old ZF1 code from pre-composer era.

Changing the code in the /src/Zend/Loader/PluginLoader.php file fixes this issue:

Line 383 (old):

            if (class_exists($className, false)) {

Fixed:

            if (class_exists($className, true)) {
@zero2one zero2one changed the title Plugins from 3th party packages can't be loaded. Plugins from 3thd party packages can't be loaded. Nov 16, 2018
zero2one added a commit to zero2one/zf1-loader that referenced this issue Nov 16, 2018
… party packages.

See diablomedia#3

The plugin loader does not load plugins from 3thd party packages (eg. https://github.com/AMOSoft/zf1-extras).

This because the loader is checking if tha class exists without allowing autoload to work.
This is old ZF1 code from pre-composer era.

Changing the code in the /src/Zend/Loader/PluginLoader.php file fixes this issue.
@zero2one zero2one changed the title Plugins from 3thd party packages can't be loaded. Plugins from 3rd party packages can't be loaded. Nov 16, 2018
@Jalle19
Copy link

Jalle19 commented Sep 3, 2019

Just stumbled upon this too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants