Quick Namespace Question

Is it possible to create objects in one namespace from another?

For example, if I am in the global namespace and I want to create an object in the config namespace, can I do it, and if so how?

The obvious appears to be something like this to me:

namespace {
    config\\$object = new config\\class();
}

This isn’t working for me however. Am I doing something wrong or is it just not possible?

I get this error:

Parse error: parse error, expecting `T_STRING’ in…


$config = new \\config\
amespace\\class();

Won’t that create the object in the current namespace? I’m wanting to create an object in a different namespace to the one I’m in, if possible.

variables do not exists in any namespace but the global namespace.

Ah, then that is the simple answer I was looking for. Cheers