There is a class which handles the internationalization.
<?php
class Language{
// ...
}
Now I created a renderer.php file which should handle all injections for HTML.
<?php
namespace Renderer;
include_once '../language.php';
function drawUserList(){
// ...
$group = Language::translate($groupName);
// ...
}
In this file I need my Language class. But my compiler throws the following error message:
Undefined type 'Renderer\Language'.
The Language class is not part of a namespace. Why adds PHP a namespace to it? And why I am not able to use the class in my namespace function?
PHP Version 7.4.26