Namespace Problem


Posted on 16th Feb 2014 07:03 pm by admin

I'm having problem with a section of code with a variable namespace.

This code works fine:
Line number On/Off | Expand/Contract $c = new AppsAdminViewsIndex;

However this code does not:
Line number On/Off | Expand/Contract echo $val[1];// Outputs AppsAdminViewsIndex; $c = new $val[1] //( ! ) Fatal error: spl_autoload() [function.spl-autoload]: Class AppsAdminViewsIndex could not be loaded in C:wampwww_devRainUrlsRouter.php on line 69

My "autoloader" (PHP handles namespace autoloading automatically):

Line number On/Off | Expand/Contract spl_autoload_extensions(".php");spl_autoload_register();

I've trawled through the manual with no luck..

No comments posted yet

Your Answer:

Login to answer
282 Like 26 Dislike
Previous forums Next forums
Other forums

Dealing with code in db query
I am dealing with C code and I need to make sure it is encoded some how to ensure its integrity and

Using two $_POST Function / Switch () statements, second does not work.
Hi all. I’m new to php and am having a problem getting $_POST Function / switch () to work. I

Something Non-Traditional. Can we solve?
I have an idea for an application here. It's mostly flash, but it couldn't work without a somewhat n

Disabling SAP menu
How do I disable SAP menu for all the users and just restrict them to User Menu in SAP ECC 6.0?

PHP5/Zend 2.0 - Resources
PHP5 Snapshots
http://snaps.php.net/

ZEND 2.0 Feature Overview and Design (PDF File

Retreiving objects from Sessions
Hi all,

I am getting really frustrated with storing and retreiving objects from a session. Bu

GIS appliction help
I found some tutorials in the internet to develop a map application I don't want to use google maps

Getting rid of quotes when printing data
Hi Guys, I use the filter_var FILTER_SANITIZE_STRING to filter the textarea input. The function esca

Mass activity scheduling
Hi experts,

Im facing some problems to deal with mass activity jobs.
When I run some

Timer control causing error
I recently decided to add a timer control to an existing page that uses AJAX on my site. As soon as

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash