How to make require_once from multiple locations on one line only?

4

For example, I'm doing this:

require_once 'Testeum.php';
require_once 'Testedois.php';
require_once 'Testetres.php';

Can you do this with a single require_once? With attribute I can put comma:

private $testeum, $testedois, $testetres;

You can do with include, require, etc ...?

    
asked by anonymous 16.07.2017 / 19:47

1 answer

3

It is not possible to have a require/include in the body of the class that generates a syntax error. It is also not possible to add an access modifier ( public , protected and private ) outside a class. The only place where it is possible is within methods.

    
17.07.2017 / 14:19