/[drupal]/contributions/modules/autoload/autoload.module
ViewVC logotype

Diff of /contributions/modules/autoload/autoload.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1.2.4, Tue Mar 17 21:54:58 2009 UTC revision 1.1.2.5, Tue Mar 17 21:57:58 2009 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: autoload.module,v 1.1.2.3 2008/12/02 05:19:39 crell Exp $  // $Id: autoload.module,v 1.1.2.4 2009/03/17 21:54:58 crell Exp $
3  /**  /**
4   * Implementation of hook_init().   * Implementation of hook_init().
5   */   */
# Line 26  function autoload_class($class) { Line 26  function autoload_class($class) {
26    }    }
27    
28     if (!empty($lookup[$class])) {     if (!empty($lookup[$class])) {
29      require_once dirname($_SERVER['SCRIPT_FILENAME']) .'/'. $lookup[$class];      // require() is safe because if the file were already included
30        // autoload wouldn't have been triggered.  The dirname() stuff
31        // is backported from Drupal 7 to get an absolute path, which
32        // includes faster on disk.
33        require dirname($_SERVER['SCRIPT_FILENAME']) .'/'. $lookup[$class];
34    }    }
35  }  }
36    

Legend:
Removed from v.1.1.2.4  
changed lines
  Added in v.1.1.2.5

  ViewVC Help
Powered by ViewVC 1.1.2