I use Zend Framework to provide a PHP version Lucene. Currently, Zned should be the best PHP wrapper for Java Lucene.
Create a Zend_Search_Lucene , using the method termFreqs to get the term frequecy for a specific term. There is no implementation in Zend for Java method like termDocs , which provides a Term => <docNum, freq>*.
So now I have to iterate all terms for figure out the frequency. But better for nothing :)
Sample code to get term frequency:
Sample code to crate index:
Sample code to search index