Where is the definition of the class "Viewclass"? Assuming you misspelled you extending the View will not work as the file containing its definition is not being included in the file it uses (Scriptview class).
In the class definition file Scriptview you need to include the class definition file View.
How will you use namespace you must use the resource of self-loading that will do the job of including these files for you using namespace as masks to directories.
For example:
namespace Myframework Base Controller;
When you use the class that is in this namespace, in the Controller example, PHP will provide the name of that class you want access to and you will point to the physical file that will be included:
Myframework/Base/Controller.php - (these extension settings and extra directories can be set in your autoload).
Here you find the link of the function that allows you to register autoload and example how to implement your own autoload.
Besides the fact that you don’t need to include your files manually you get a performance gain by not including unused classes, that is, the loading of these classes will be on demand.
Thank you very much.
– Faro