Hi:
I have tried to import a file "helper" with
JHtml::addIncludePath(JPATH_COMPONENT.'/helpers'); but throws me an error saying that the class is not found.
JHtml::addIncludePath(JPATH_COMPONENT.'/helpers');vgalleryHelperRoute::getGalleryRoute();
output:
Class 'vgalleryHelperRoute' not found in ......
However, if I do this, everything works properly:
if(!defined('DS')){
define('DS',DIRECTORY_SEPARATOR);
}
require_once (JPATH_COMPONENT.DS.'helpers'.DS.'route.php');
vgalleryHelperRoute::getGalleryRoute();
What am I doing wrong with "JHtml::addIncludePath()"?