0

Sorry about my English but I have a problem:

I making application for search with using Zend_Search_Lucene. I try find phrase "T-Mobile" but without anything answers. I know symbol "-" is a special. What I have to do cover this symbol "-" ?

My code which I made :

if ($this->getRequest()->getParam('as_epq', false)){
  $search = new App_Search();
  $phraze = explode(' ', $this->getRequest()->getParam('as_epq'));
  if ($this->getRequest()->getParam('as_epq_place', false)){
    $place = $this->getRequest()->getParam('as_epq_place');
    $this->view->as_epq_place = $place;
    $query = new Zend_Search_Lucene_Search_Query_Phrase($phraze, null, $place);
  }else{
    $query = new Zend_Search_Lucene_Search_Query_Phrase($phraze);
  }
  $this->view->as_epq = $this->getRequest()->getParam('as_epq'); 
  $results = $search->getIndex()->find($query);
}

I don't know where is my error ?

gaza
  • 1
  • 4

1 Answers1

0

You can escape special characters using '/'.

k4mrcy
  • 3
  • 2