In Zend Studio, how to determine the type of a variable, so what do I have autocomplete?

In php we use include. Thus, variables defined in one file and then their scope also include files. Zend Studio does not know how to get the type of the variable that I use inside the included file, it is very annoying when the type of the variable is a big class.
Is there a way to hint at the ideal about variable types? in the included files?

+5
source share
3 answers

I have an article about some Zend Studio code completion tips and PDT code completion tips that might help. However, it is recommended that you try to limit the variables required from other files. This can easily be done for complex code maintenance.

+3
source

Here is a manual recording of the oldest Zend Studio 5.

/* @var $router \Core\Router */
$router = Registry::get("router");
$router->route();

This feature also works in the new Zend Studio, including version 10!

+4
source
foreach($A as $AnInstance)
/*@var MyClass $AnInstance*/
$AnInstance->doSomething();
+1
source

All Articles