/products/photocrati_nextgen/modules/ngglegacy/ngg-config.php

  1. <?php 
  2. /** 
  3. * Bootstrap file for getting the ABSPATH constant to wp-load.php 
  4. * This is requried when a plugin requires access not via the admin screen. 
  5. * 
  6. * If the wp-load.php file is not found, then an error will be displayed 
  7. * 
  8. * @package WordPress 
  9. * @since Version 2.6 
  10. */ 
  11.  
  12. /** Define the server path to the file wp-config here, if you placed WP-CONTENT outside the classic file structure */ 
  13.  
  14. $path = ''; // It should be end with a trailing slash 
  15.  
  16. /** That's all, stop editing from here **/ 
  17.  
  18. if ( !defined('WP_LOAD_PATH') ) { 
  19.  
  20. // classic root path if wp-content and plugins is below wp-config.php 
  21. $legacy_root = dirname(dirname(dirname(dirname(__FILE__)))) . '/' ; 
  22.  
  23. // root path when ngglegacy is embedded as a Pope module 
  24. $pope_root = dirname(dirname(dirname(dirname($legacy_root)))) . '/'; 
  25.  
  26. if (file_exists( $legacy_root . 'wp-load.php') ) 
  27. define( 'WP_LOAD_PATH', $legacy_root); 
  28. elseif (file_exists( $pope_root.'wp-load.php' ) ) 
  29. define( 'WP_LOAD_PATH', $pope_root ); 
  30. else 
  31. if (file_exists( $path . 'wp-load.php') ) 
  32. define( 'WP_LOAD_PATH', $path); 
  33. else 
  34. throw new RuntimeException("Could not find wp-load.php"); 
  35.  
  36. // let's load WordPress 
  37. require_once( WP_LOAD_PATH . 'wp-load.php'); 
.