Changes
Title
unchanged
Adding search to Yii blog example (using Zend Lucene)
Category
unchanged
Tutorials
Yii version
unchanged
Tags
unchanged
blog, demo, search, zend, zf, lucene, tutorial
Content
changed
[...]
<?php else: ?>
<p class="error">No results matched your search terms.</p>
<?php endif; ?>
```
As you can see because I passed to the view the $query, I can use Zend's highlightMatches ...<br>
(if your search result
s not in english, you might have some encoding issues with highlightMatches
), so you might consider using your own highlighter for greater flexibility and encoding issues free)<br>
Also I created a real link from the linked I passed and created via
**$doc->addField(Zend_Search_Lucene_Field::Text('link' ...**
And thats it
try to search the word "it"[...]