the-art-of-joomla-archive /redirect/code/trunk/administrator/components/com_redirect/libraries/loader.php

Language PHP Lines 52
MD5 Hash c3759002d7c292a54844f5fd37d5297b Estimated Cost $329 (why?)
Repository https://bitbucket.org/eddieajau/the-art-of-joomla-archive View Raw File View Project SPDX
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
/**
 * @version		$Id: loader.php 576 2011-02-25 05:03:45Z eddieajau $
 * @package		NewLifeInIT
 * @subpackage	com_artofpdf
 * @copyright	Copyright 2005 - 2011 New Life in IT Pty Ltd. All rights reserved.
 * @license		GNU General Public License version 2 or later.
 * @link		http://www.theartofjoomla.com
 * @author		Andrew Eddie <support@theartofjoomla.com>
 */

// no direct access
defined('_JEXEC') or die;

/**
 * Replacement for jimport that falls back to jimport.
 *
 * @param	string	$path	The library path.
 *
 * @return
 * @since	1.0
 * @author	Sam Moffat
 */
function juimport($path)
{
	// Attempt to load the path locally but...
	// Unfortunately 1.5 doesn't check the file exists before including it so we mask it
	$res = JLoader::import($path, dirname(__FILE__));

	if (!$res) {
		// fall back when it doesn't work
		return jimport($path);
	}

	return $res;
}

if (!function_exists('jximport')) {
	/**
	 * Proxy for juimport function.
	 *
	 * @param	string	$path	The library path.
	 *
	 * @return
	 * @since	1.0
	 */
	function jximport($path)
	{
		return juimport($path);
	}
}
Back to Top