I am trying to implement Lucene with cakephp and following this guide http://jamienay.com/2010/01/zend_search_lucene-datasource-for-cakephp/
Am getting this error
ConnectionManager::loadDataSource - Unable to import DataSource class .ZendSearchLuceneSource
i have placed the Vendor files in app/vendors/Zend/
Added this in the bootstrap.php
ini_set('include_path', ini_get('include_path') . ':' . CAKE_CORE_INCLUDE_PATH . DS . '/vendors');
/**
* AutoLoading Zend Vendor Files
*/
function __autoload($path) {
if(substr($path, 0, 5) == 'Zend_') {
include str_replace('_', '/', $path) . '.php';
}
return $path;
}
added this to the Database Config
var $zendSearchLucene = array(
'datasource' => 'ZendSearchLucene',
'indexFile' => 'lucene', // stored in the cache dir.
'driver' => '',
'source' => 'search_indices'
);
Add created a model called search.php
<?php
class Search extends AppModel {
var $useDbConfig = 'zendSearchLucene';
}
?>
Right now i have created a controller called search too like this
<?php
class SearchController extends AppController {
var $name = 'Search';
function index(){
}
}
?>
when i visit site/search am getting that error.