PHP extension functions and classes in PhpStorm

Are extension functions suitable for extension for IDE, for example PHPStorm, when they are given the path to the php.ini file of the path to the extension folder? I saw that the EasyPHP list functions for the extension included in its composition come with it, but do not display any functions for Yaf and Phalcon that are installed manually.

+4
source share
4 answers

For Phalcon - create the Phalcon Developer Tools ( http://phalconphp.com/download ) - it contains stub files that the IDE can use to complete the code: https://github.com/phalcon/phalcon-devtools/tree/master / ide / phpstorm

For Yaf - a similar approach (a stub file for use inside the IDE): https://github.com/suin/phpstorm-yaf-doc

+4
source

Since these frameworks are php extensions, just make sure you configure php include path in the IDE correctly.

config -> PHP -> and add something like / usr / share / php there (your location)

+1
source

I use the plugs provided on the package and install them with the help of the composer. https://packagist.org/packages/sneakybobito/phalcon-stubs

composer.json

{ "require": { "sneakybobito/phalcon-stubs": "1.2.3" } } 
+1
source

For compiled extensions, you will need a stub file that contains the name of the functions. Since the latest versions of PHP include reflection capabilities for extensions [you can get extensions, certain classes and functions, and then mirror them to get their parameters], they should be able to generate them.

I give https://github.com/schmittjoh/php-stubs a try, but the PHP svn server is not working at the moment, so it will not work ... Let's try checking here later and update if it works.

0
source

Source: https://habr.com/ru/post/1439122/


All Articles