This website can use cookies to improve the user experience

This website can use cookies to improve the user experience and to provide certain services and functions to users. Cookies contain small amounts of information (such as login information and user preferences) and will be stored on your device.

Enable All Cookies Privacy Policy

Feature Request - whole article search


avatar
johngaltnh 0
From: -
Feature Request - whole article search

Hi Phillip,

I have a feature request. I would like the "Search" function to work on more than just the titles of stories, but on the complete article text.

If this functionality already exists, how do I use it?

Thank you!

Notice

This topic is archived. New comments cannot be posted and votes cannot be cast.

Responses to this topic


1 Re: Feature Request - whole article search
avatar
Administrator
1340
From: Vienna, Austria
Feature Request - whole article search

Yes, the CMS is expecting InnoDB on MySQL 4.0

To convert to InnoDB:
Click on "Click here to upgrade to InnoDB tables" on the admin main screen

If this option is not available, check your my.cnf for "skip-innodb" and remove or comment out this line. Then restart MySQL.

To build the search index:
Logout/login. Other => Search Index
1 Re: Feature Request - whole article search
avatar
OP 0
From: -
Feature Request - whole article search

Hi Phillip,

I am actually running MySQL 4.0.14-standard. Is the search not working right because I should have done something explicit when setting up the database to use InnoDB tables instead of MyISAM?

Most of the tables are in MyISAM format. (Except for cache being in HEAP format.)

Am I reading the code right that if I convert the MyISAM tables to InnoDB, the search function will work on story text too without modifying the code?

Thank you!
1 Re: Feature Request - whole article search
avatar
Administrator
1340
From: Vienna, Austria
Feature Request - whole article search

Sounds like you are running MySQL 3.23?

You need to replace review_title with review_text in search.php:
if ($where == "2") $result = DBQuery("SELECT * FROM esselbach_st_review WHERE (review_text LIKE '%$query%') and review_website = '$website' and review_page = '1' OR (review_text LIKE '%$query%') and review_website = '0' and review_page = '1' ORDER BY review_id DESC LIMIT $start,100"); 


Alternatively, there is already support for MySQL 4.0's boolean full-text search feature in the CMS

Notice

This topic is archived. New comments cannot be posted and votes cannot be cast.