View Single Post
Old 05-09-2009, 09:40 PM   #12 (permalink)
allworknoplay
The Gregarious
 
allworknoplay's Avatar
 
Join Date: Feb 2009
Location: New York
Posts: 645
Thanks: 64
allworknoplay is on a distinguished road
Default

Hi,

I went with WH's suggestion and created a loader class called: allclass.php and put that into my "includes" folder. So my tree looks like..


/www
/www/includes/
/www/images/


I have a header.html file that calls the allclass.php like this:
(/www/header.html)

PHP Code:
Loader::loadClass('includes/allclass.php'); 
And in the allclass.php, I have it very simple with this:


PHP Code:
<?php


class Loader{

include_once(
'database.php');

}

?>

But when I run my header.html file, I get this error:


Fatal error: Class 'Loader' not found.....
allworknoplay is offline  
Reply With Quote